結果

問題 No.164 ちっちゃくないよ!!
ユーザー kou6839kou6839
提出日時 2015-03-13 00:31:01
言語 Java21
(openjdk 21)
結果
AC  
実行時間 221 ms / 2,000 ms
コード長 596 bytes
コンパイル時間 2,526 ms
コンパイル使用メモリ 83,768 KB
実行使用メモリ 55,344 KB
最終ジャッジ日時 2024-04-21 15:21:38
合計ジャッジ時間 5,397 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 155 ms
54,212 KB
testcase_01 AC 158 ms
54,136 KB
testcase_02 AC 158 ms
54,028 KB
testcase_03 AC 158 ms
54,112 KB
testcase_04 AC 163 ms
54,324 KB
testcase_05 AC 220 ms
54,504 KB
testcase_06 AC 221 ms
54,684 KB
testcase_07 AC 213 ms
54,400 KB
testcase_08 AC 216 ms
55,344 KB
testcase_09 AC 216 ms
54,932 KB
testcase_10 AC 169 ms
54,624 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.beans.IntrospectionException;
import java.util.*;

class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		long ans = Long.MAX_VALUE;
		for(int i=0;i<n;i++){
			long temp=0;
			String string = sc.next();
			int max=49;
			for(int j=0;j<string.length();j++){
				max=Math.max(max,(int)string.charAt(j));
			}
			if(max<60){
				max=max-48+1;
			}else{
				max=max-55+1;
			}
			for(int j=0;j<string.length();j++){
				temp=Long.parseLong(string, max);
			}
			ans=Math.min(ans, temp);
		}
		System.out.println(ans);
	}
}
0