You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
446 B
22 lines
446 B
#include <bits/stdc++.h>
|
|
|
|
using namespace std;
|
|
int i, j, n, K, cnt, a[1000];
|
|
|
|
int main() {
|
|
for (i = 6; i < 10000; i++) {
|
|
n = i;
|
|
cnt = 0;
|
|
for (j = 1; j <= 5; j++)
|
|
if (n % 5 == 1 && n / 5 > 0) {
|
|
n = n - n / 5 - 1;
|
|
cnt++;
|
|
}
|
|
if (cnt == 5) {
|
|
a[k] = i;
|
|
k++;
|
|
}
|
|
}
|
|
printf("%d\n", a[0]);
|
|
return 0;
|
|
} |