結果
| 問題 |
No.651 E869120 and Driving
|
| コンテスト | |
| ユーザー |
@abcde
|
| 提出日時 | 2019-02-16 01:33:07 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 1,000 ms |
| コード長 | 488 bytes |
| コンパイル時間 | 1,278 ms |
| コンパイル使用メモリ | 161,284 KB |
| 実行使用メモリ | 6,944 KB |
| 最終ジャッジ日時 | 2024-09-22 09:06:30 |
| 合計ジャッジ時間 | 1,773 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 7 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
int main() {
// 1. 入力情報取得.
int a;
cin >> a;
// 2. 目的地まで何分かかる?
int total = 60 * a / 100;
int hour = 10 + total / 60;
int minute = (total % 60);
// 3. 出力.
string ans = to_string(hour);
ans += {':'};
if(minute < 10) ans += {'0'}, ans += to_string(minute);
if(minute >= 10) ans += to_string(minute);
cout << ans << endl;
return 0;
}
@abcde