2 条题解
-
1
本题代码如下,先写出所有的可能性的判断语句,然后还有一个重点就是当n等于0时,它要输出1。希望给一个赞。不像某些人,要写小文章去我的资料写!
#include <bits/stdc++.h> using namespace std; int main() { int R; cin >> R; if (R == 0) cout << 1; else if (1 <= R && R < 99) cout << 100 - R; else if (100 <= R && R < 199) cout << 200 - R; else if (200 <= R && R < 299) cout << 300 - R; return 0; }
- 1
信息
- ID
- 18091
- 时间
- 1000ms
- 内存
- 256MiB
- 难度
- 2
- 标签
- 递交数
- 95
- 已通过
- 62
- 上传者