Class C# Tutorial

Methods return a value to the calling routine using this form of return:

return value;
value is the value returned.

using System;
class MainClass
{
   public static int GetHour()
   {
      return 123;                   
   }
   static void Main()
   {
      Console.WriteLine("Hour: {0}", GetHour());
   }
}
Hour: 123