結果
問題 | No.501 穴と文字列 |
ユーザー |
|
提出日時 | 2019-08-17 23:19:46 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 3 ms / 2,000 ms |
コード長 | 342 bytes |
コンパイル時間 | 1,749 ms |
コンパイル使用メモリ | 193,052 KB |
最終ジャッジ日時 | 2025-01-07 13:55:36 |
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 22 |
ソースコード
#include <bits/stdc++.h>using namespace std;typedef long long ll;int main() {int n,d;cin>>n>>d;if (n>=d) {n-=d;while (d--) cout<<'A';while (n--) cout<<'C';} else {d-=n;n-=d;while (n--) cout<<'A';while (d--) cout<<'B';}cout<<endl;return 0;}