結果
| 問題 | No.2371 最大の試練それは起床 | 
| コンテスト | |
| ユーザー |  poyon | 
| 提出日時 | 2023-06-11 22:32:36 | 
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 2 ms / 2,000 ms | 
| コード長 | 599 bytes | 
| コンパイル時間 | 2,073 ms | 
| コンパイル使用メモリ | 195,772 KB | 
| 最終ジャッジ日時 | 2025-02-14 01:53:50 | 
| ジャッジサーバーID (参考情報) | judge5 / judge2 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 19 | 
ソースコード
// 別解(文字列の辞書順比較)
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
    ios::sync_with_stdio(false);
    cin.tie(nullptr);
    cout << fixed << setprecision(15);
    string H, M;
    cin >> H >> M;
    if ((int)H.size() == 1) { H = "0" + H; }
    if ((int)M.size() == 1) { M = "0" + M; }
    string t = H + M;
    string S = "0730";
    string T = "0830";
    string ans;
    if (t < S) {
        ans = "Yes";
    } else if (t < T) {
        ans = "Late";
    } else {
        ans = "No";
    }
    cout << ans << '\n';
    return 0;
}
            
            
            
        