結果
問題 | No.536 人工知能 |
ユーザー |
![]() |
提出日時 | 2019-02-20 21:11:56 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 2 ms / 1,000 ms |
コード長 | 941 bytes |
コンパイル時間 | 910 ms |
コンパイル使用メモリ | 93,144 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-11-07 16:43:19 |
合計ジャッジ時間 | 1,327 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 11 |
ソースコード
#include <iostream>#include <istream>#include <sstream>#include <fstream>#include <string>#include <vector>#include <deque>#include <queue>#include <stack>#include <set>#include <map>#include <algorithm>#include <functional>#include <utility>#include <bitset>#include <cmath>#include <cstdlib>#include <ctime>#include <cstdio>using namespace std;#define REP(i, n) for(int i = 0; i < n;i++)typedef long long ll;int main() {ios::sync_with_stdio(false);cin.tie(0);/*int n, m;int a[110];cin >> n >> m;for (int i = 0; i < n; i++) cin >> a[i];for (int i = 0; i < m; i++) {for (int j = 0; j < n; j++) {if (j % i > (j + 1) % i) swap(a[i], a[i + 1]);}}cout << a[0];for (int i = 0; i < n; i++) cout << a[i] << endl;*/string s;cin >> s;int l = s.length();if (s[l - 2] == 'a' && s[l - 1] == 'i') {s[l - 2] = 'A';s[l - 1] = 'I';} else {s = s + "-AI";}cout << s << endl;}