結果
| 問題 | No.3678 しゃべりすぎた男 |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2026-09-05 13:06:45 |
| 言語 | C++23(gcc16) (gcc 16.1.0 + boost 1.92.0) |
| 結果 |
AC
|
| 実行時間 | 1 ms / 2,000 ms |
| + 301µs | |
| コード長 | 379 bytes |
| 記録 | |
| コンパイル時間 | 1,063 ms |
| コンパイル使用メモリ | 172,372 KB |
| 実行使用メモリ | 6,272 KB |
| 最終ジャッジ日時 | 2026-09-05 13:07:13 |
| 合計ジャッジ時間 | 2,687 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 33 |
ソースコード
#include<iostream>
#include<vector>
#include<algorithm>
using namespace std;
using ll = long long;
int main(void){
int mx=6000, now=0;
bool imp=false;
for(int i=0; i<7; i++){
int t; cin >> t;
if(imp||t==-1){
imp=true;
cout << -1 << endl; continue;
}
now+=t;
if(now>mx) cout << -1 << endl;
else cout << mx-now << endl;
}
return 0;
}