結果
問題 |
No.1229 ラグビーの得点パターン
|
ユーザー |
![]() |
提出日時 | 2020-09-20 02:32:23 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 495 bytes |
コンパイル時間 | 726 ms |
コンパイル使用メモリ | 90,740 KB |
実行使用メモリ | 6,948 KB |
最終ジャッジ日時 | 2024-06-24 01:09:35 |
合計ジャッジ時間 | 1,800 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 WA * 1 |
other | AC * 16 WA * 9 |
ソースコード
#include<iostream> #include<stdio.h> #include<stdlib.h> #include<algorithm> #include<vector> #include<string.h> #include<math.h> #include<map> #include<iomanip> #include<queue> using ll = long long; const int inf = 99999999; using namespace std; int main(){ int n; cin >> n; int ans = 0; for(int i = 1; i <= 30; i++){ for(int j = 0; j <= 30; j++){ for(int k = 0; k <= 40; k++){ if(5*i + 2*j + 3*k == n){ if(i>=j)ans++; } } } } cout << ans << endl; return 0; }