예제 #1
0
        public static void employeeDetails()
        {
            employee e = new employee();
            e.name = "Himakar";
            e.dob = "09-10-1993";
            e.city = "Bangalore";
            string EmployeeCode = "AZ016";

            Console.WriteLine("Enter your employee code : ");
            string x = Console.ReadLine().ToUpper();
            if (EmployeeCode == x)
            {
                Console.WriteLine("\nEMPLOYEE DETAILS \n");
                Console.WriteLine("NAME : {0} \nDOB : {1} \nLOCATON : {2} ",
                                    e.name, e.dob, e.city);

                Console.ReadLine();
            }
            else
            {
                Console.WriteLine("You entered the wrong code..");
                Console.ReadLine();
            }
        }