public static void Main()
OutRef.RefExample(ref t);
Console.WriteLine("Finished Ref : {0}", t);
Console.Write("\n\n\n\n\n");
OutRef.OutExample(out string x);
Console.WriteLine("Finished Out : {0}", x);
public static class OutRef
public static void RefExample(ref int a)
Console.WriteLine("Before Ref: Int a = {0}", a);
Console.WriteLine("After Ref: Int a = {0}", a);
public static void OutExample(out string b)
Console.WriteLine("Before Out : {0}", TestForNull(b));
private static bool TestForNull(string a)