Using Integers

image_pdfimage_print
   
 
using System;

public class UsingIntegers
{
  static void Main(string[] args)
  {
    int MyInt = 12345;
    long MyLong = MyInt;
    
  }

  public long My2ndFunction(long MyLong)
  {
    try
    {
      long c = checked(MyLong * 500);
    }
    catch (OverflowException e)
    {
      Console.WriteLine(e);
    }

    return 0;
  }
}

           
         
     


This entry was posted in Data Types. Bookmark the permalink.