結果

問題 No.211 素数サイコロと合成数サイコロ (1)
ユーザー chankou0920chankou0920
提出日時 2017-10-20 11:11:22
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 63 ms / 1,000 ms
コード長 406 bytes
コンパイル時間 2,208 ms
コンパイル使用メモリ 104,908 KB
実行使用メモリ 24,688 KB
最終ジャッジ日時 2023-09-08 06:25:15
合計ジャッジ時間 5,845 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 59 ms
20,676 KB
testcase_01 AC 58 ms
22,688 KB
testcase_02 AC 61 ms
24,528 KB
testcase_03 AC 61 ms
22,624 KB
testcase_04 AC 61 ms
22,496 KB
testcase_05 AC 63 ms
24,688 KB
testcase_06 AC 60 ms
20,604 KB
testcase_07 AC 58 ms
18,752 KB
testcase_08 AC 62 ms
22,772 KB
testcase_09 AC 59 ms
20,660 KB
testcase_10 AC 58 ms
22,764 KB
testcase_11 AC 62 ms
22,796 KB
testcase_12 AC 58 ms
22,772 KB
testcase_13 AC 60 ms
20,652 KB
testcase_14 AC 58 ms
20,828 KB
testcase_15 AC 58 ms
20,656 KB
testcase_16 AC 59 ms
20,668 KB
testcase_17 AC 60 ms
20,592 KB
testcase_18 AC 61 ms
24,644 KB
testcase_19 AC 58 ms
20,560 KB
testcase_20 AC 60 ms
22,820 KB
testcase_21 AC 58 ms
20,676 KB
testcase_22 AC 59 ms
22,824 KB
testcase_23 AC 59 ms
22,656 KB
testcase_24 AC 60 ms
22,668 KB
testcase_25 AC 59 ms
20,672 KB
testcase_26 AC 59 ms
20,612 KB
testcase_27 AC 60 ms
22,652 KB
testcase_28 AC 59 ms
22,720 KB
testcase_29 AC 58 ms
20,600 KB
testcase_30 AC 59 ms
22,700 KB
testcase_31 AC 59 ms
20,752 KB
testcase_32 AC 58 ms
20,608 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System;

public class Program {
	public static void Main(string[] args) {
		int k = int.Parse(Console.ReadLine());
		int[] a = {2, 3, 5, 7, 11, 13};
		int[] b = {4, 6, 8, 9, 10, 12};
		int count = 0;
		for (int i = 0; i < a.Length; i++) {
			for (int j = 0; j < b.Length; j++) {
				if (a[i] * b[j] == k) {
					count++;
				}
			}
		}
		Console.WriteLine(count / (double)(a.Length * b.Length));
	}
}
0