結果

問題 No.327 アルファベット列
ユーザー tentententen
提出日時 2021-01-18 18:58:47
言語 Java21
(openjdk 21)
結果
AC  
実行時間 125 ms / 2,000 ms
コード長 320 bytes
コンパイル時間 2,105 ms
コンパイル使用メモリ 72,252 KB
実行使用メモリ 56,368 KB
最終ジャッジ日時 2023-08-21 02:02:35
合計ジャッジ時間 11,804 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 120 ms
56,076 KB
testcase_01 AC 120 ms
55,964 KB
testcase_02 AC 120 ms
55,960 KB
testcase_03 AC 120 ms
55,608 KB
testcase_04 AC 125 ms
55,796 KB
testcase_05 AC 122 ms
55,456 KB
testcase_06 AC 120 ms
55,948 KB
testcase_07 AC 121 ms
55,984 KB
testcase_08 AC 120 ms
55,772 KB
testcase_09 AC 124 ms
55,652 KB
testcase_10 AC 123 ms
55,668 KB
testcase_11 AC 122 ms
55,744 KB
testcase_12 AC 122 ms
55,900 KB
testcase_13 AC 123 ms
56,148 KB
testcase_14 AC 122 ms
53,540 KB
testcase_15 AC 122 ms
55,852 KB
testcase_16 AC 121 ms
55,712 KB
testcase_17 AC 123 ms
55,352 KB
testcase_18 AC 123 ms
55,728 KB
testcase_19 AC 123 ms
55,532 KB
testcase_20 AC 123 ms
55,356 KB
testcase_21 AC 123 ms
55,776 KB
testcase_22 AC 120 ms
55,740 KB
testcase_23 AC 123 ms
55,884 KB
testcase_24 AC 124 ms
55,744 KB
testcase_25 AC 122 ms
55,896 KB
testcase_26 AC 120 ms
55,780 KB
testcase_27 AC 120 ms
55,964 KB
testcase_28 AC 120 ms
56,000 KB
testcase_29 AC 121 ms
55,952 KB
testcase_30 AC 120 ms
55,604 KB
testcase_31 AC 124 ms
55,352 KB
testcase_32 AC 122 ms
55,596 KB
testcase_33 AC 121 ms
55,856 KB
testcase_34 AC 120 ms
55,864 KB
testcase_35 AC 122 ms
53,436 KB
testcase_36 AC 125 ms
55,836 KB
testcase_37 AC 123 ms
55,916 KB
testcase_38 AC 124 ms
55,732 KB
testcase_39 AC 121 ms
56,140 KB
testcase_40 AC 123 ms
56,368 KB
testcase_41 AC 124 ms
55,736 KB
testcase_42 AC 122 ms
55,856 KB
testcase_43 AC 124 ms
55,628 KB
testcase_44 AC 123 ms
56,008 KB
testcase_45 AC 121 ms
55,576 KB
testcase_46 AC 119 ms
55,692 KB
testcase_47 AC 119 ms
55,540 KB
testcase_48 AC 120 ms
55,716 KB
testcase_49 AC 119 ms
55,760 KB
testcase_50 AC 119 ms
55,640 KB
testcase_51 AC 120 ms
55,540 KB
testcase_52 AC 120 ms
55,724 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Main {
	public static void main (String[] args) {
		Scanner sc = new Scanner(System.in);
		long n = sc.nextLong();
		StringBuilder sb = new StringBuilder();
		while (n >= 0) {
		    sb.append((char)(n % 26 + 'A'));
		    n /= 26;
		    n--;
		}
		System.out.println(sb.reverse());
	}
}
0