結果
| 問題 | No.525 二度寝の季節 |
| コンテスト | |
| ユーザー |
moti
|
| 提出日時 | 2017-08-13 16:47:42 |
| 言語 | C++17 (gcc 13.3.0 + boost 1.89.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 237 bytes |
| 記録 | |
| コンパイル時間 | 2,273 ms |
| コンパイル使用メモリ | 192,556 KB |
| 最終ジャッジ日時 | 2025-01-05 02:18:53 |
|
ジャッジサーバーID (参考情報) |
judge4 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 2 |
| other | WA * 33 |
コンパイルメッセージ
main.cpp: In function ‘int main()’:
main.cpp:16:8: warning: too many arguments for format [-Wformat-extra-args]
16 | printf("%02d:02d\n", b/60%24, a[1]%60);
| ^~~~~~~~~~~~
ソースコード
#include <bits/stdc++.h>
int main() {
std::stringstream ss;
std::string s;
int k = 0;
int a[2] {};
while(ss>>s) {
if(s == ":") {
k++;
} else {
std::cin >> a[k];
}
}
int b = a[0] * 60 + a[1] + 5;
printf("%02d:02d\n", b/60%24, a[1]%60);
}
moti