結果
| 問題 | No.501 穴と文字列 |
| コンテスト | |
| ユーザー |
777yuuki12323
|
| 提出日時 | 2017-04-08 00:03:05 |
| 言語 | C++11 (gcc 15.3.0 + boost 1.92.0) |
| 結果 |
AC
不安定
|
| 実行時間 | 1 ms / 2,000 ms |
| + 560µs | |
| コード長 | 637 bytes |
| 記録 | |
| コンパイル時間 | 292 ms |
| コンパイル使用メモリ | 82,968 KB |
| 実行使用メモリ | 9,864 KB |
| 最終ジャッジ日時 | 2026-10-03 14:00:47 |
| 合計ジャッジ時間 | 1,834 ms |
|
ジャッジサーバーID (参考情報) |
judge1_1 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 22 |
ソースコード
#include <iostream>
#include <cstdio>
#include <algorithm>
#include <string>
#include <map>
typedef long long ll;
#define fi first
#define se second
using namespace std;
int N;
int D;
#define mod 1000000000000
//123456789012
int main(){
cin>>N>>D;
int s;
int i;
s = N - D;
if( s > 0 ){
for( i = 0; i < D; i++ ){
printf("A");
}
for( i = 0; i < s; i++ ){
printf("C");
}
puts("");
}
else{
s *= -1;
D = N - s;
for( i = 0; i < D; i++ ){
printf("A");
}
for( i = 0; i < s; i++ ){
printf("B");
}
puts("");
}
return 0;
}
777yuuki12323