結果

問題 No.547 未知の言語
ユーザー kohaku_kohakukohaku_kohaku
提出日時 2017-07-28 22:25:29
言語 Java21
(openjdk 21)
結果
AC  
実行時間 132 ms / 2,000 ms
コード長 628 bytes
コンパイル時間 3,677 ms
コンパイル使用メモリ 71,172 KB
実行使用メモリ 56,672 KB
最終ジャッジ日時 2023-09-08 09:06:13
合計ジャッジ時間 8,679 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 122 ms
56,084 KB
testcase_01 AC 124 ms
56,140 KB
testcase_02 AC 124 ms
55,732 KB
testcase_03 AC 124 ms
56,100 KB
testcase_04 AC 125 ms
56,008 KB
testcase_05 AC 126 ms
56,076 KB
testcase_06 AC 124 ms
55,880 KB
testcase_07 AC 128 ms
55,940 KB
testcase_08 AC 125 ms
56,100 KB
testcase_09 AC 127 ms
55,616 KB
testcase_10 AC 132 ms
56,176 KB
testcase_11 AC 125 ms
56,096 KB
testcase_12 AC 123 ms
56,276 KB
testcase_13 AC 124 ms
55,940 KB
testcase_14 AC 124 ms
55,732 KB
testcase_15 AC 123 ms
56,672 KB
testcase_16 AC 126 ms
55,460 KB
testcase_17 AC 124 ms
55,920 KB
testcase_18 AC 127 ms
55,928 KB
testcase_19 AC 123 ms
55,696 KB
testcase_20 AC 124 ms
55,800 KB
testcase_21 AC 125 ms
55,900 KB
testcase_22 AC 127 ms
56,140 KB
testcase_23 AC 123 ms
54,044 KB
testcase_24 AC 129 ms
56,300 KB
testcase_25 AC 125 ms
55,684 KB
testcase_26 AC 124 ms
56,032 KB
testcase_27 AC 125 ms
56,028 KB
testcase_28 AC 122 ms
55,412 KB
testcase_29 AC 126 ms
55,416 KB
testcase_30 AC 125 ms
55,616 KB
testcase_31 AC 124 ms
56,052 KB
testcase_32 AC 124 ms
56,092 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int N = sc.nextInt();
        String [] S = new String [N];
        String [] T = new String [N];
        for(int i=0; i<N; i++){
            S[i] = sc.next();
        }
        for(int i=0; i<N; i++){
            T[i] = sc.next();
        }
        for(int i=0; i<N; i++){
            if(!S[i].equals(T[i])){
                System.out.println(i+1);
                System.out.println(S[i]);
                System.out.println(T[i]);
                break;
            }
        }
    }
}
0