結果

問題 No.744 循環小数N桁目 Easy
ユーザー hhgfhn1hhgfhn1
提出日時 2018-10-19 21:29:14
言語 Java21
(openjdk 21)
結果
AC  
実行時間 128 ms / 2,000 ms
コード長 257 bytes
コンパイル時間 3,272 ms
コンパイル使用メモリ 71,848 KB
実行使用メモリ 56,088 KB
最終ジャッジ日時 2023-08-12 00:08:52
合計ジャッジ時間 5,466 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 125 ms
55,352 KB
testcase_01 AC 124 ms
55,968 KB
testcase_02 AC 128 ms
55,588 KB
testcase_03 AC 127 ms
56,088 KB
testcase_04 AC 124 ms
55,560 KB
testcase_05 AC 125 ms
55,792 KB
testcase_06 AC 125 ms
55,776 KB
testcase_07 AC 124 ms
55,732 KB
testcase_08 AC 123 ms
55,984 KB
testcase_09 AC 126 ms
55,748 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class Main {

	@SuppressWarnings("resource")
	public static void main(String args[]) {
		Scanner scanner = new Scanner(System.in);
		int n=scanner.nextInt();
		int a[]={2,8,5,7,1,4};
		System.out.println(a[(n-1)%6]);
	}
}

0