#include<stdio.h>
#include<stdlib.h>

int GCD(int a, int b);

void main() {
  int a, b;
  printf("Enter any two positive integers:\n");
  scanf("%d %d", & a, & b);
  GCD(a, b);
}

int GCD(int a, int b) {
  if (b != 0) {
    return GCD(b, a % b);
  } else {
    printf("GCD is %d", a);
    exit(0);
  }
}
     
           
Note: Need to be arranged in compiler after copied
   

 OutPut:

Enter any two positive integers: 10 15 GCD is 5