This commit is contained in:
HuangHai
2025-08-30 18:35:01 +08:00
commit 1f397eca87
6258 changed files with 1487241 additions and 0 deletions

25
LuoGu/RuMen/P1151.cpp Normal file
View File

@@ -0,0 +1,25 @@
#include<iostream>
using namespace std;
int main() {
int K;
cin >> K;
int count = 0;
for (int i = 10000; i <= 30000; i++) {
int sub1 = i / 100;
int sub2 = (i - i / 10000 * 10000) / 10;
int sub3 = i % 1000;
if (sub1 % K == 0 && sub2 % K == 0 && sub3 % K == 0) {
cout << i << endl;
count++;
}
}
if (count == 0) {
cout << "No" << endl;
}
return 0;
}