結果

問題 No.118 門松列(2)
ユーザー roiti46roiti46
提出日時 2015-02-09 23:59:51
言語 Python2
(2.7.18)
結果
AC  
実行時間 116 ms / 5,000 ms
コード長 246 bytes
コンパイル時間 572 ms
コンパイル使用メモリ 7,040 KB
実行使用メモリ 12,004 KB
最終ジャッジ日時 2024-04-17 12:52:37
合計ジャッジ時間 3,748 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 68 ms
6,400 KB
testcase_01 AC 115 ms
12,004 KB
testcase_02 AC 113 ms
11,692 KB
testcase_03 AC 116 ms
11,912 KB
testcase_04 AC 114 ms
11,984 KB
testcase_05 AC 114 ms
11,968 KB
testcase_06 AC 65 ms
6,016 KB
testcase_07 AC 65 ms
6,272 KB
testcase_08 AC 64 ms
6,272 KB
testcase_09 AC 111 ms
11,524 KB
testcase_10 AC 73 ms
7,424 KB
testcase_11 AC 76 ms
7,936 KB
testcase_12 AC 71 ms
7,168 KB
testcase_13 AC 67 ms
6,656 KB
testcase_14 AC 110 ms
11,432 KB
testcase_15 AC 64 ms
6,272 KB
testcase_16 AC 89 ms
9,336 KB
testcase_17 AC 68 ms
6,528 KB
testcase_18 AC 77 ms
7,808 KB
testcase_19 AC 86 ms
8,704 KB
testcase_20 AC 88 ms
9,088 KB
testcase_21 AC 102 ms
10,496 KB
testcase_22 AC 74 ms
7,680 KB
testcase_23 AC 98 ms
10,368 KB
testcase_24 AC 78 ms
7,936 KB
testcase_25 AC 85 ms
8,832 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

mod = 10**9+7
N = int(raw_input())
h = [0]*100
for i in map(int,raw_input().split()): h[i-1] += 1
ans = 0
for i in range(100):
    for j in range(i+1,100):
        for k in range(j+1,100):
            ans = (ans+h[i]*h[j]*h[k]%mod)%mod
print ans
0