結果

問題 No.744 循環小数N桁目 Easy
ユーザー kohaku_kohakukohaku_kohaku
提出日時 2019-02-19 18:33:52
言語 Java21
(openjdk 21)
結果
AC  
実行時間 124 ms / 2,000 ms
コード長 294 bytes
コンパイル時間 1,856 ms
コンパイル使用メモリ 73,916 KB
実行使用メモリ 41,288 KB
最終ジャッジ日時 2024-04-20 17:48:44
合計ジャッジ時間 3,646 ms
ジャッジサーバーID
(参考情報)
judge1 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 115 ms
41,236 KB
testcase_01 AC 119 ms
40,968 KB
testcase_02 AC 118 ms
41,228 KB
testcase_03 AC 122 ms
40,076 KB
testcase_04 AC 114 ms
40,928 KB
testcase_05 AC 122 ms
41,124 KB
testcase_06 AC 111 ms
40,756 KB
testcase_07 AC 124 ms
41,288 KB
testcase_08 AC 117 ms
40,816 KB
testcase_09 AC 106 ms
40,236 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Main {

    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        final String NUM = "285714";
        char c = NUM.charAt( (n-1)%6 );
        System.out.println(c);
    }
}
0