How can you instantiate a tuple?

Answer

The following are two ways to instantiate a tuple:

  • Using the new operator. For example,
    Tuple<String, int> t = new Tuple<String, int> ("Hellow", 2);
  • Using the Create factory method available in the Tuple class. For example,
    Tuple<int, int, int> t = Tuple.Create<int, int, int> (2, 4, 5);

All .net Questions

Ask your interview questions on net

Write Your comment or Questions if you want the answers on net from net Experts
Name* :
Email Id* :
Mob no* :
Question
Or
Comment* :
 





Disclimer: PCDS.CO.IN not responsible for any content, information, data or any feature of website. If you are using this website then its your own responsibility to understand the content of the website

--------- Tutorials ---