Bob103

C#_1(begin)

Sep 17th, 2016
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.73 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6.  
  7. namespace ConsoleApplication1
  8. {
  9.     class Program
  10.     {
  11.         static void Main(string[] args)
  12.         {
  13.             int a;
  14.             Console.Write("Enter a=");
  15.             a =Convert.ToInt32( Console.ReadLine());
  16.  
  17.             if (a / 100 > (a / 10) % 10)
  18.             {
  19.                 Console.WriteLine("First more then second");
  20.             }
  21.  
  22.             else if (a / 100 < (a / 10) % 10)
  23.             {
  24.                 Console.WriteLine("Second  more then first");
  25.             }
  26.  
  27.             else if (a / 100 == (a / 10) % 10)
  28.             { Console.WriteLine("Same :)"); }
  29.         }
  30.     }
  31. }
Advertisement
Add Comment
Please, Sign In to add comment