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.

17 lines
400 B

#include <bits/stdc++.h>
using namespace std;
int main() {
for (int i = 0; i <= 20; i++) {
for (int j = 0; j <= 34; j++) {
for (int k = 0; k <= 300; k += 3) {
if (i * 5 + j * 3 + k / 3 == 100 && i + j + k == 100) {
cout << i << " " << j << " " << k << endl;
}
}
}
}
return 0;
}