--%>

Instantiated of Tuple

How a tuple can be instantiated?

E

Expert

Verified

Following are the two ways to instantiate a tuple:

a) By using the new operator.
For instance,
Tuple<String, int> t = new Tuple<String, int> ("Hellow", 2);

b)  By using the Create factory procedure which is available in the Tuple class.
For example,
Tuple<int, int, int> t = Tuple.Create<int, int, int> (2, 4, 5);

   Related Questions in DOT NET Programming