Output parameter in C#

Sourav.Kayal
Posted by Sourav.Kayal under C# category on | Points: 40 | Views : 878
using System;
using System.Linq;
using System.Text;
using System.Collections;
using System.IO;
using System.Diagnostics;
using System.Collections.Generic;
namespace BlogProject
{
class Program
{
public static int TestOut(out char i)
{
i = 'b';
return -1;
}

static void Main(string[] args)
{
char i;
Console.WriteLine(TestOut(out i));
Console.WriteLine(i);
Console.ReadLine();
}
}
}

Comments or Responses

Login to post response