結果

問題 No.1764 Square
ユーザー takabatake2911
提出日時 2021-12-30 23:15:55
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
RE  
実行時間 -
コード長 877 bytes
コンパイル時間 1,555 ms
コンパイル使用メモリ 161,484 KB
実行使用メモリ 6,820 KB
最終ジャッジ日時 2024-10-07 01:35:47
合計ジャッジ時間 2,512 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 2 RE * 3
権限があれば一括ダウンロードができます

ソースコード

diff #

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

int main() {
    string s = "EABCDEABCD";
    int n;
    cin >> n;
    string t = s.substr((5 - n / 4) % 5, 5);
    if (n % 4 == 0) {
        cout << t[1];
        cout << t[0] << endl;
        cout << t[2] << endl;
        cout << t[3] << endl;
        cout << t[4] << endl;
    }
    if (n % 4 == 1) {
        cout << t[0] << endl;
        cout << t[2];
        cout << t[1] << endl;
        cout << t[3] << endl;
        cout << t[4] << endl;
    }
    if (n % 4 == 2) {
        cout << t[0] << endl;
        cout << t[1] << endl;
        cout << t[3];
        cout << t[2] << endl;
        cout << t[4] << endl;
    }
    if (n % 4 == 3) {
        cout << t[0] << endl;
        cout << t[1] << endl;
        cout << t[2] << endl;
        cout << t[4];
        cout << t[3] << endl;
    }
    return 0;
}
0