結果

問題 No.313 π
ユーザー ki_ki33ki_ki33
提出日時 2015-12-06 08:41:00
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 1,180 bytes
コンパイル時間 3,351 ms
コンパイル使用メモリ 78,752 KB
実行使用メモリ 65,060 KB
最終ジャッジ日時 2023-10-12 16:34:37
合計ジャッジ時間 14,156 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
testcase_08 AC 271 ms
60,540 KB
testcase_09 AC 275 ms
59,884 KB
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 WA -
testcase_20 WA -
testcase_21 AC 261 ms
60,728 KB
testcase_22 WA -
testcase_23 WA -
testcase_24 AC 272 ms
61,088 KB
testcase_25 WA -
testcase_26 WA -
testcase_27 AC 265 ms
59,852 KB
testcase_28 WA -
testcase_29 WA -
testcase_30 WA -
testcase_31 WA -
testcase_32 WA -
testcase_33 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.awt.Point;
import java.awt.Rectangle;
import java.awt.geom.Rectangle2D;
import java.io.BufferedInputStream;
import java.io.IOException;
import java.math.BigDecimal;
import java.math.BigInteger;
import java.util.*;
import java.util.Map.Entry;
import java.util.concurrent.ConcurrentSkipListSet;

public class Main {
	static final long C =  1000000007;
	static final int CY = 1000000000;
	//long[] F;

	int[] nums = new int[]{ 20104
			, 20063
			, 19892
			, 20011
			, 19874
			, 20199
			, 19898
			, 20163
			, 19955
			,19841};

	public void calc() {
		StringBuilder sb = new StringBuilder();
		BufferedInputStream bs = new BufferedInputStream(System.in);
		Scanner sc = new Scanner(bs);

		int now[] = new int[10];


		int ans1 = 0, ans2 =0;
		String s = sc.next();
		for (int i=0; i < s.length() ; i++ ) {
			char c = s.charAt(i);
			try {
				now[c - '0']++;
			}catch (Exception e) {
			}
		}
		
		for (int i=0; i < 10; i++) {
			if (nums[i] < now[i]) {
				ans1 = i;
			}else if (nums[i] > now[i]) {
				ans2 = i;
			}
		}

		System.out.println(ans1 +" "+ ans2);

	}






	public static void main(String[] args) {
		Main main = new Main();
		main.calc();

	}
}
0