using System;
public class Program
{
public static void Main()
int a, b;
Console.WriteLine(" намиране на НОД");
Console.Write(" а=" );
a = int.Parse(Console.ReadLine());
Console.WriteLine(" b =");
b = int.Parse(Console.ReadLine());
while ( a!=b)
if ( a > b) a=a-b;
else b = b-a;
}
Console.WriteLine("НОД е" +a);