結果

問題 No.3043 yukicoderへようこそ!
ユーザー xuzijian629xuzijian629
提出日時 2019-04-01 22:24:37
言語 C++17
(gcc 12.3.0 + boost 1.83.0)
結果
WA  
実行時間 -
コード長 484 bytes
コンパイル時間 2,096 ms
コンパイル使用メモリ 198,468 KB
実行使用メモリ 4,380 KB
最終ジャッジ日時 2023-08-18 01:32:43
合計ジャッジ時間 2,545 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 AC 2 ms
4,376 KB
testcase_04 WA -
testcase_05 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;

void solve1() {
    cout << "Hello World!" << endl;
}

bool solved2;
void solve2(stringstream& ss) {
    if (solved2) {

    } else {
        int n;
        ss >> n;
        cout << n * (n + 1) / 2 << endl;
    }
}

int main() {
    stringstream ss;
    char c;
    while ((c = getchar()) != EOF) {
        ss << c;
    }
    if (ss.str().size() == 0) {
        solve1();
    } else if (ss.str().size() < 4) {
        solve2(ss);
    }
}
0