예제 #1
0
        static void Use()
        {
            Digit a      = (Digit)5;
            Digit b      = (Digit)3;
            Digit plus   = a + b;
            Digit minus  = a - b;
            bool  equals = (a == b);

            Console.WriteLine("{0} + {1} = {2}", a, b, plus);
            Console.WriteLine("{0} - {1} = {2}", a, b, minus);
            Console.WriteLine("{0} == {1} = {2}", a, b, equals);
        }
예제 #2
0
 void Main()
 {
     Digit d = (Digit)8;
     byte b = d;
 }