結果

問題 No.536 人工知能
ユーザー shinwisteriashinwisteria
提出日時 2018-02-16 22:11:28
言語 Java21
(openjdk 21)
結果
AC  
実行時間 132 ms / 1,000 ms
コード長 370 bytes
コンパイル時間 5,539 ms
コンパイル使用メモリ 73,860 KB
実行使用メモリ 55,732 KB
最終ジャッジ日時 2023-09-05 05:14:20
合計ジャッジ時間 7,916 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 128 ms
55,640 KB
testcase_01 AC 127 ms
55,564 KB
testcase_02 AC 127 ms
55,296 KB
testcase_03 AC 127 ms
55,732 KB
testcase_04 AC 127 ms
53,812 KB
testcase_05 AC 125 ms
55,432 KB
testcase_06 AC 128 ms
55,552 KB
testcase_07 AC 130 ms
55,716 KB
testcase_08 AC 130 ms
55,304 KB
testcase_09 AC 130 ms
55,504 KB
testcase_10 AC 132 ms
55,560 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

package m.shin;
import java.util.Scanner;
public class Con536 {

	public static void main(String[] args) {
		Scanner s = new Scanner(System.in);
		String str = s.nextLine();
		s.close();
		if(str.substring(str.length()-2, str.length()).equals("ai")){
			System.out.println(str.substring(0,str.length()-2) + "AI");
		}else{
			System.out.println(str + "-AI");
		}

	}

}
0