#include <stdio.h>

int ppcm(int m, int n) {
  int tmp_m = m;
  int tmp_n = n;
  while (m != n) {
    if (m < n) {
      m += tmp_m;
    } else {
      n += tmp_n;
    }
  }
  return m;
}

int main() {
  int m = 36;
  int n = 90;

  printf("the ppcm is %d\n", ppcm(m, n));
  return 0;
}
