結果
問題 | No.1229 ラグビーの得点パターン |
ユーザー |
|
提出日時 | 2020-09-18 21:21:41 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 3 ms / 2,000 ms |
コード長 | 211 bytes |
コンパイル時間 | 438 ms |
コンパイル使用メモリ | 64,628 KB |
実行使用メモリ | 6,948 KB |
最終ジャッジ日時 | 2024-06-22 08:21:42 |
合計ジャッジ時間 | 1,267 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 25 |
コンパイルメッセージ
main.cpp:4:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type] 4 | main() | ^~~~
ソースコード
#include<iostream>using namespace std;int N;main(){cin>>N;int ans=0;for(int t=0;t<=100;t++)for(int g=0;g<=100;g++)for(int pg=0;pg<=100;pg++){if(t>=g&&5*t+2*g+3*pg==N)ans++;}cout<<ans<<endl;}