Assistance needed with Task.ContinueWith()
Maybe I am missing something petty (will remove post if that is the case). Can someone tell me what I am doing wrong with this .ContinueWith() ? I do not see the result printed in the screen.

    public static void Main()
            {
                Task<int> t = new Task<int>(() => { return Sum(5); });
                t.Start();
                t.Wait();
                t.ContinueWith((task) => { Console.WriteLine(task.Result); });
                //Console.WriteLine(t.Result); //this works
    
            }
            public static int Sum(int n)
            {
                return 50;//stub result
            }
Assistance needed with Task.ContinueWith()
===

Maybe I am missing something petty (will remove post if that is the case). Can someone tell me what I am doing wrong with this .ContinueWith() ? I do not see the result printed in the screen.

    public static void Main()
            {
                Task<int> t = new Task<int>(() => { return Sum(5); });
                t.Start();
                t.Wait();
                t.ContinueWith((task) => { Console.WriteLine(task.Result); });
                //Console.WriteLine(t.Result); //this works
    
            }
            public static int Sum(int n)
            {
                return 50;//stub result
            }