結果
問題 | No.2198 Concon Substrings (COuNt-CONstruct Version) |
ユーザー |
![]() |
提出日時 | 2023-01-20 23:40:26 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 3 ms / 2,000 ms |
コード長 | 972 bytes |
コンパイル時間 | 1,755 ms |
コンパイル使用メモリ | 193,184 KB |
最終ジャッジ日時 | 2025-02-10 05:51:26 |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 104 |
ソースコード
#include<bits/stdc++.h> using namespace std; #define rep(i,n) for (int i=0;i<(int)(n);i++) #define all(v) v.begin(),v.end() using ll=long long; using pll=pair<ll,ll>; using tll=tuple<ll,ll,ll>; const ll INF=(1ll<<60); template<class T> void chmin(T &a,T b){ if(a>b){ a=b; } } template<class T> void chmax(T &a,T b){ if(a<b){ a=b; } } ll modpow(ll a,ll b,ll mod){ if(b==0) return 1; ll p=a,ret=1; for(ll i=0;i<=62;i++){ if(b&(1ll<<i)){ ret*=p; ret%=mod; } p=(p%mod)*(p%mod); p%=mod; } return ret; } int main(){ ll m; cin >> m; if(m==0){ cout << "a" << endl; return 0; } ll a=m/(ll)1e8; m%=(ll)1e8; ll b=m/(ll)1e4; m%=(ll)1e4; rep(i,a) cout << "c"; rep(i,1e4) cout << "o"; rep(i,9998) cout << "n"; rep(i,b) cout << "c"; rep(i,9999) cout << "o"; rep(i,m) cout << "c"; cout << "on" << endl; }