結果
| 問題 |
No.1229 ラグビーの得点パターン
|
| コンテスト | |
| ユーザー |
t33f
|
| 提出日時 | 2020-09-18 22:22:05 |
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 287 bytes |
| コンパイル時間 | 625 ms |
| コンパイル使用メモリ | 66,716 KB |
| 最終ジャッジ日時 | 2025-01-14 17:23:23 |
|
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 25 |
ソースコード
#include <iostream>
using namespace std;
int main() {
int n; cin >> n;
int ans = 0;
for (int a = 0; a < 100; a++)
for (int b = 0; b <= a; b++)
for (int c = 0; c < 100; c++)
if (5 * a + 2 * b + 3 * c == n) ans++;
cout << ans << endl;
}
t33f