The first passes the obj task. The second passes the value of obj .
To see the difference, assign something else to obj after creating the task.
public static void PrintMe(object obj) { Task task = new Task(() => { Console.WriteLine(obj.ToString()); }); obj = "Surprise"; task.Start(); }
source share