結果

問題 No.224 文字列変更(easy)
ユーザー dazydazy
提出日時 2017-02-27 14:31:40
言語 Java21
(openjdk 21)
結果
AC  
実行時間 129 ms / 5,000 ms
コード長 422 bytes
コンパイル時間 3,149 ms
コンパイル使用メモリ 72,712 KB
実行使用メモリ 58,104 KB
最終ジャッジ日時 2023-09-25 02:22:38
合計ジャッジ時間 6,938 ms
ジャッジサーバーID
(参考情報)
judge13 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 123 ms
54,116 KB
testcase_01 AC 129 ms
55,856 KB
testcase_02 AC 124 ms
55,484 KB
testcase_03 AC 125 ms
56,056 KB
testcase_04 AC 125 ms
56,232 KB
testcase_05 AC 123 ms
54,172 KB
testcase_06 AC 123 ms
55,804 KB
testcase_07 AC 124 ms
56,472 KB
testcase_08 AC 124 ms
56,272 KB
testcase_09 AC 120 ms
56,096 KB
testcase_10 AC 120 ms
56,188 KB
testcase_11 AC 123 ms
55,812 KB
testcase_12 AC 124 ms
56,012 KB
testcase_13 AC 122 ms
56,392 KB
testcase_14 AC 122 ms
56,256 KB
testcase_15 AC 127 ms
55,640 KB
testcase_16 AC 125 ms
56,504 KB
testcase_17 AC 129 ms
58,104 KB
testcase_18 AC 127 ms
55,908 KB
testcase_19 AC 129 ms
56,324 KB
testcase_20 AC 127 ms
56,088 KB
testcase_21 AC 125 ms
55,968 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Run {
    public static void main (String arg[]) {
        Scanner scan = new Scanner(System.in);
        int ans = 0;

        int length = scan.nextInt();
        String S = scan.next();
        String T = scan.next();

        for (int i = 0; i < length; i++) {
            if (!S.substring(i, i+1).equals(T.substring(i, i+1))) ans++;
        }
        System.out.println(ans);
    }
}
0