Return an instance of a class
<p>I have the following classes:</p>

<p>MinMaxArray class:</p>

<pre><code>public class MinMaxArray
{
  public static &lt;T&gt; void MinMax(T[] anArray)
  {
    //return an instance of class Pair
  }//MinMax
}//class MinMaxArray
</code></pre>

<p>Pair class:</p>

<pre><code>//Two objects grouped into a pair.
public class Pair&lt;FirstType, SecondType&gt;
{
  //The first object.
  private final FirstType first;

  //The second object.
  private final SecondType second;

  //Constructor is given the two objects.
  public Pair(FirstType requiredFirst, SecondType requiredSecond)
  {
    first = requiredFirst;
    second = requiredSecond;
  }//Pair



  //Return the first object.
  public FirstType getFirst()
  {
    return first;
  }//GetFirst


  //Return the second object.
  public SecondType getSecond()
  {
    return second;
  }//GetSecond

}//class Pair
</code></pre>

<p>I'm not sure how i can go about returning an instance of the Pair class. Not looking for answers, just a starting point. Thanks</p>
