GATEverse
← GATE CSE 2004

Q41

MCQ2 marks, −0.5

Consider the following C program main() { int x, y, m, n; scanf("%d %d", &x, &y); /* Assume x>0 and y>0*/ m = x; n = y; while(m != n) { if (m > n) m = m-n; else n = n-m; } printf("%d", n); } The program computes

Sign in to save attempts.

Loading…