title: How to programatically set the selected state for a segment in UISegmentedControl
body: <p>I have four segments in my UISegmentedControl. I am trying to programmatically set the selected state of the third and fourth segments <strong>at the same time</strong> if the user has selected the first segment.</p>
  
  <p>Example: In a given segmented control, if the user selected segment A, then C, D should be selected. </p>
  
  <p>I looked into Apple's methods but found none that match my requirement. I am looking for a method that would look like-</p>
  
  <p>Any help on this is much appreciated. </p>
  
  <hr>
  
  <p>-(void) setSelected: (BOOL) selected forSegmentAtIndex: (NSUInteger) segment</p>
  
  <p><strong>Parameters</strong></p>
  
  <p><em>enabled</em></p>
  
  <p>YES to select the specified segment or NO to unselect the segment. By default, segments are unselected.</p>
  
  <p><em>segment</em></p>
  
  <p>An index number identifying a segment in the control. It must be a number between 0 and the number of segments (numberOfSegments) minus 1; values exceeding this upper range are pinned to it.</p>
  
  <hr>