title: How to open a nth fragment hosted by an activity with the help of intent?
body: <p>I have an activity with 12 fragments. And another activity with 12 buttons. I want to open the 1st fragment when I clicked the 1st button, 2nd fragment by clicking the 2nd button and so on. But I can open only the activity and always the first fragment opens with it. For the nth fragment, I have to scroll every time. </p>
  
  <p>My app is showing 12 teams names and while clicking on one team it opens full squad list. All the squad fragments (12 fragments) are hosted by an activity. I want to open the squad fragment as per the team.</p>
  
  <p>code</p>
  
  <pre><code>Intent i = new Intent(getActivity(),SquadActivity.class);
                                  startActivity(i);
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/kdd4h.png" rel="nofollow noreferrer">Team Name</a></p>
  
  <p><a href="https://i.stack.imgur.com/DIFBB.png" rel="nofollow noreferrer">Squad list</a></p>