結果
| 問題 |
No.70 睡眠の重要性!
|
| コンテスト | |
| ユーザー |
LV3zJigVW57oPGy
|
| 提出日時 | 2022-11-09 12:09:45 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 625 bytes |
| コンパイル時間 | 3,029 ms |
| コンパイル使用メモリ | 162,548 KB |
| 実行使用メモリ | 6,944 KB |
| 最終ジャッジ日時 | 2024-07-22 18:29:08 |
| 合計ジャッジ時間 | 1,966 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 5 WA * 1 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
#include <ios>
#include <iomanip>
#include <iostream>
#include <string>
#include <algorithm>
int main(){
double count=0;
int number;
cin >> number;
for(int i=0; i<number; i++){
stringstream ss;
string str;
cin >> str;
int a, b;
ss << str;
ss >> a;
ss.ignore();
ss >> b;
stringstream ss2;
string str2;
cin >> str2;
int d, c;
ss2 << str2;
ss2 >> c;
ss2.ignore();
ss2 >> d;
double e;
double f;
if(a>=12&&c<12){
e=(23-a)+c;
}
else{
e=fabs(a-c)-1;
}
count += e*60+ fabs(60-b+d);
}
cout << count;
}
LV3zJigVW57oPGy