結果

問題 No.224 文字列変更(easy)
ユーザー mobius_bkstmobius_bkst
提出日時 2015-06-12 22:26:17
言語 Java21
(openjdk 21)
結果
AC  
実行時間 45 ms / 5,000 ms
コード長 704 bytes
コンパイル時間 3,458 ms
コンパイル使用メモリ 78,588 KB
実行使用メモリ 49,424 KB
最終ジャッジ日時 2023-09-25 01:58:54
合計ジャッジ時間 5,553 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 44 ms
49,248 KB
testcase_01 AC 44 ms
49,060 KB
testcase_02 AC 45 ms
49,060 KB
testcase_03 AC 45 ms
48,868 KB
testcase_04 AC 45 ms
49,332 KB
testcase_05 AC 44 ms
47,096 KB
testcase_06 AC 44 ms
47,408 KB
testcase_07 AC 44 ms
49,148 KB
testcase_08 AC 45 ms
49,320 KB
testcase_09 AC 44 ms
48,856 KB
testcase_10 AC 43 ms
49,036 KB
testcase_11 AC 44 ms
49,160 KB
testcase_12 AC 44 ms
49,124 KB
testcase_13 AC 44 ms
47,284 KB
testcase_14 AC 44 ms
49,424 KB
testcase_15 AC 45 ms
48,920 KB
testcase_16 AC 44 ms
49,424 KB
testcase_17 AC 43 ms
49,156 KB
testcase_18 AC 44 ms
48,920 KB
testcase_19 AC 44 ms
48,904 KB
testcase_20 AC 44 ms
49,148 KB
testcase_21 AC 44 ms
49,040 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.io.BufferedReader;
import java.io.InputStreamReader;

public class No224 {
    public static void main(String[] args) {
        try {
            BufferedReader br = new BufferedReader(new InputStreamReader(
                    System.in));
            int N = Integer.parseInt(br.readLine());
            char[] S = br.readLine().toCharArray();
            char[] T = br.readLine().toCharArray();
            int count = 0;
            for (int i = 0; i < N; i++) {
                if (S[i] != T[i])
                    count++;
            }

            System.out.println(count);
        } catch (Exception e) {
            System.err.println("Error:" + e.getMessage());
        }
    }
}
0