結果
| 問題 | No.536 人工知能 | 
| コンテスト | |
| ユーザー |  rankBBNT | 
| 提出日時 | 2017-07-04 21:12:20 | 
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 2 ms / 1,000 ms | 
| コード長 | 282 bytes | 
| コンパイル時間 | 502 ms | 
| コンパイル使用メモリ | 55,688 KB | 
| 実行使用メモリ | 6,820 KB | 
| 最終ジャッジ日時 | 2024-10-05 16:04:28 | 
| 合計ジャッジ時間 | 937 ms | 
| ジャッジサーバーID (参考情報) | judge2 / judge5 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | AC * 11 | 
ソースコード
#include <iostream>
#include <string>
using namespace std;
int main(void){
	string name;
	cin >> name;
	int len = name.length();
	if (name[len - 2] == 'a' && name[len - 1] == 'i') {
		cout << name.substr(0, len - 2) << "AI" << endl;
	}
	else {
		cout << name << "-AI" << endl;
	}
}
            
            
            
        