title: How to select item in collectionview programmatically?
body: <p>I have a <code>UICollectionView</code>. The <code>UICollectionView</code>'s <code>datasource</code> is a <code>NSArray</code> of students (from <code>CoreData</code>). I want the current  student item be <code>selected</code>/<code>highlighted</code>.</p>
  
  <p>How can I do this? I know there is a method:</p>
  
  <pre><code>- (void)selectItemAtIndexPath:(NSIndexPath *)indexPath 
                       animated:(BOOL)animated 
                 scrollPosition:(UICollectionViewScrollPosition)scrollPosition;
  </code></pre>
  
  <p>which takes as arguments an <code>NSIndexPath</code> and <code>UICollectionViewScrollPosition</code>.</p>
  
  <p>I have the datasource (<code>NSArray</code> of students populated from <code>CoreData</code>) and the student object to be <code>selected</code>.</p>
  
  <p>So, how do I get the <code>NSIndexPath</code> and <code>UICollectionViewScrollPosition</code>?
  Or is there any other way to highlight an item?</p>