結果

問題 No.69 文字を自由に並び替え
ユーザー dogwood0424dogwood0424
提出日時 2017-12-01 23:32:57
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 390 bytes
コンパイル時間 3,168 ms
コンパイル使用メモリ 74,000 KB
実行使用メモリ 56,472 KB
最終ジャッジ日時 2023-09-09 21:23:40
合計ジャッジ時間 6,028 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 121 ms
55,820 KB
testcase_02 WA -
testcase_03 WA -
testcase_04 AC 121 ms
55,772 KB
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 AC 122 ms
55,580 KB
testcase_10 AC 123 ms
55,832 KB
testcase_11 WA -
testcase_12 WA -
testcase_13 AC 122 ms
55,748 KB
testcase_14 AC 121 ms
55,776 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Arrays;
import java.util.Scanner;

public class No69 {
	public static void main(String[]args) {
		Scanner sc = new Scanner(System.in);

		String A = sc.next();
		String B = sc.next();

		char[]a=A.toCharArray();
		char[]b=B.toCharArray();

		Arrays.sort(a);
		Arrays.sort(b);

		if(a==b) {
			System.out.println("YES");
		}
		else {
			System.out.println("NO");
		}


	}

}
0