public string name; public int age;
public string university; public string category;
public void doctor(string n, int a, string u, string c)
name=n; age=a; university=u; category=c;
public void printdoctor()
Console.WriteLine("Doctor name:{0}", name);
Console.WriteLine("Doctor age: {0}",age);
Console.WriteLine("Doctor university: {0}",university);
Console.WriteLine("Doctor category: {0}",category);
{ Console.WriteLine("\nMInii ner bol - "+name);}
private static string name;
{ Console.WriteLine("nMy name is" + name);}
public static int basepow;
static int power (int po)
{ return basepow*power(po-1);}
public static void Main()
Console.WriteLine("Bodlogiin dugaaraa oruulna uu");
opt= Convert.ToInt32(Console.ReadLine());
Console.WriteLine("---Bod1--");
string na; int ag; string un; string ca;
Doctor doc = new Doctor();
Console.Write("Enter Doctor name:"); na= Console.ReadLine();
Console.Write("Enter Doctor age:"); ag= Convert.ToInt16(Console.ReadLine());
Console.Write("Enter Doctor university:"); un= Console.ReadLine();
Console.Write("Enter Doctor category:"); ca= Console.ReadLine();
doc.doctor( na, ag, un, ca);
Console.WriteLine("---Bod2--");
access1 ac1 = new access1();
Console.Write("Enter your name:\t");
ac1.name = Console.ReadLine(); ac1.print();
Console.WriteLine("---Bod3--");
access2 ac2 = new access2();
Console.Write("Enter your name:\t");
ac2.Name = Console.ReadLine(); ac2.print();
Console.WriteLine("---Bod4--");
Console.Write("Зэрэг:"); int pow = Convert.ToInt32(Console.ReadLine());
Console.Write("Суурь:"); basepow = Convert.ToInt32(Console.ReadLine());
int n= power(pow); Console.WriteLine("Result: {0}",n);
Console.WriteLine("---Bod5--");
Console.Write("Факториал олох дугаараа оруулна уу??: ");
int n1 = Convert.ToInt32(Console.ReadLine());
Console.WriteLine(n1.ToString()+ "!="+r.ToString());
default: Console.WriteLine("Buruu dugaar baina !!!!");
Console.WriteLine("Dakhin ekhluuleh bol y tovchiig darna uu");
if (a == "y") { goto label;