結果

問題 No.1146 土偶Ⅰ
ユーザー wolgnikwolgnik
提出日時 2020-08-05 21:12:44
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 85 ms / 2,000 ms
コード長 236 bytes
コンパイル時間 221 ms
コンパイル使用メモリ 81,580 KB
実行使用メモリ 68,056 KB
最終ジャッジ日時 2023-10-17 14:25:28
合計ジャッジ時間 2,879 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 39 ms
53,560 KB
testcase_01 AC 37 ms
53,560 KB
testcase_02 AC 37 ms
53,560 KB
testcase_03 AC 47 ms
61,912 KB
testcase_04 AC 83 ms
68,056 KB
testcase_05 AC 51 ms
61,912 KB
testcase_06 AC 62 ms
63,960 KB
testcase_07 AC 75 ms
66,008 KB
testcase_08 AC 85 ms
68,056 KB
testcase_09 AC 56 ms
61,912 KB
testcase_10 AC 47 ms
61,912 KB
testcase_11 AC 61 ms
63,960 KB
testcase_12 AC 84 ms
68,056 KB
testcase_13 AC 38 ms
53,560 KB
testcase_14 AC 54 ms
61,912 KB
testcase_15 AC 78 ms
68,056 KB
testcase_16 AC 59 ms
63,960 KB
testcase_17 AC 36 ms
53,560 KB
testcase_18 AC 41 ms
59,864 KB
testcase_19 AC 56 ms
61,912 KB
testcase_20 AC 42 ms
59,864 KB
testcase_21 AC 46 ms
59,864 KB
testcase_22 AC 44 ms
59,864 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
from itertools import combinations as combi
from math import gcd
input = sys.stdin.readline
N = int(input())
a = [int(input()) for _ in range(N)]
res = 0
for c in combi(a, 3): res += gcd(gcd(c[0], c[1]), c[2]) == 1
print(res)
0