結果

問題 No.2775 Nuisance Balls
ユーザー GOTKAKO
提出日時 2024-06-07 21:26:23
言語 C++17
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 384 bytes
コンパイル時間 1,980 ms
コンパイル使用メモリ 196,232 KB
最終ジャッジ日時 2025-02-21 19:42:42
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 22
権限があれば一括ダウンロードができます

ソースコード

diff #

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

int main() {
    ios_base::sync_with_stdio(false);
    cin.tie(nullptr);

    vector<int> A = {720,360,180,30,6,1};
    vector<char> C = {'C','M','S','R','o','.'};

    int N; cin >> N;
    int idx = 0;
    for(auto a : A){
        int loop = N/a; N %= a;
        while(loop--) cout << C.at(idx);
        idx++;
    }
    cout << endl;
}
0