# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
1129401 | jackofall718 | Palindromic FizzBuzz (NOI19_palindrome) | C++20 | 23 ms | 1864 KiB |
//2019 NOI prelim
#include <bits/stdc++.h>
using namespace std;
long long S, E;
bool is_palindrome(long long x) {
vector<int> v;
while (x > 0) {
v.push_back(x%10);
x /= 10;
}
for (int i = 0; i < v.size(); i++) if (v[i] != v[v.size() - i - 1]) return false;
return true;
}
int main() {
scanf("%lld%lld", &S, &E);
for (long long i = S; i <= E; i++) {
if (is_palindrome(i)) printf("Palindrome!\n");
else printf("%lld\n", i);
}
}
컴파일 시 표준 에러 (stderr) 메시지
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |