結果
| 問題 | No.143 豆 |
| コンテスト | |
| ユーザー |
cande398
|
| 提出日時 | 2018-03-26 21:54:00 |
| 言語 | C++11 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 1,000 ms |
| コード長 | 138 bytes |
| 記録 | |
| コンパイル時間 | 141 ms |
| コンパイル使用メモリ | 37,504 KB |
| 実行使用メモリ | 6,400 KB |
| 最終ジャッジ日時 | 2026-04-03 13:58:43 |
| 合計ジャッジ時間 | 989 ms |
|
ジャッジサーバーID (参考情報) |
judge3_1 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 17 |
コンパイルメッセージ
main.cpp:2:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
2 | main()
| ^~~~
ソースコード
#include <stdio.h>
main()
{
int N,K,F;
scanf("%d%d%d",&K,&N,&F);
for(N=K*N;F--;){
scanf("%d",&K);N-=K;
}
printf("%d\n",N<0?-1:N);
}
cande398