結果
| 問題 | No.3487 Restricted Shiritori |
| コンテスト | |
| ユーザー |
UT0911
|
| 提出日時 | 2026-03-22 22:59:31 |
| 言語 | C (gcc 15.2.0) |
| 結果 |
AC
|
| 実行時間 | 1 ms / 2,000 ms |
| コード長 | 251 bytes |
| 記録 | |
| コンパイル時間 | 1,312 ms |
| コンパイル使用メモリ | 36,704 KB |
| 実行使用メモリ | 41,216 KB |
| 最終ジャッジ日時 | 2026-04-01 20:51:24 |
| 合計ジャッジ時間 | 2,201 ms |
|
ジャッジサーバーID (参考情報) |
judge1_1 / judge3_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 25 |
ソースコード
#include<stdio.h>
int main(){
char s,e;
int N;
scanf("%c %c %d",&s,&e,&N);
if(N==1){
if(s==e){
printf("%c\n",s);
}else{
printf("-1\n");
}
}else{
printf("%c",s);
for(int i=0;i<N-2;i++){
printf("a");
}
printf("%c\n",e);
}
}
UT0911