[Solved] Value type and reference type with c#.NET code sample? [closed]
[ad_1] The function fool1 doesn’t change the args variable from the calling method. It only changes it inside the fool method (so the reference changes). string a = “x”; fool1(a); // a is still “x” Function fool2 DOES change the args variable from the calling method. string a = “x”; fool2(ref a); // a is … Read more