21 lines
315 B
C
21 lines
315 B
C
#include <stdio.h>
|
|
|
|
int ggT(int a, int b) {
|
|
if(a==0) return b;
|
|
while(b!=0) {
|
|
if(a > b) a -= b;
|
|
else b -= a;
|
|
}
|
|
return a;
|
|
}
|
|
|
|
int main( int argc, char *argv[] ) {
|
|
int n = 1;
|
|
for(int i = 20; i > 1; i--) {
|
|
if(n%i!=0) n*=i/ggT(i,n);
|
|
}
|
|
|
|
printf("%d\n",n);
|
|
|
|
return 0;
|
|
}
|