알고리즘/BOJ
[C++] 백준 3507번 Automated Telephone Exchange
Jay, Lee
2021. 2. 27. 20:49
간단한 입출력 문제
문제가 번역이 안되어 있어서 좀 그랬을 뿐!
#include <iostream>
using namespace std;
int main() {
int num;
cin >> num;
int count = 0;
if (num <= 198) {
for (int k = 1; k < 100; k++) {
for (int i = 1; i < 100; i++) {
if ((k + i) == num) {
count += 1;
}
}
}
}
cout << count << "\n";
return 0;
}