Answers for "c# return any of two type"

C#
10

c# return two variables of different types

(string, string, int) LookupName(long id) // tuple return type
{
    ... // retrieve first, middle and myNum from data storage
    return (first, middle, myNum); // tuple literal
}
Posted by: Guest on March-20-2020
1

c# return two values

public void getValues( out int i, out int j)
{
  i = // output 1;
  j = // output 2;
}
Posted by: Guest on March-05-2021

C# Answers by Framework

Browse Popular Code Answers by Language