結果

問題 No.133 カードゲーム
ユーザー yayo256
提出日時 2018-11-15 10:38:31
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
WA  
実行時間 -
コード長 320 bytes
コンパイル時間 182 ms
コンパイル使用メモリ 12,672 KB
実行使用メモリ 11,008 KB
最終ジャッジ日時 2024-12-24 13:52:52
合計ジャッジ時間 1,582 ms
ジャッジサーバーID
(参考情報)
judge4 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3 WA * 1
other AC * 3 WA * 16
権限があれば一括ダウンロードができます

ソースコード

diff #

from itertools import permutations, product

def int_or_float(n):
	return int(n) if n%1 == 0 else n

n = int(input())
a, b = [list(map(int, input().split(" "))) for _ in range(2)]

print(int_or_float(sum(sum(a_i>b_i for a_i, b_i in zip(*x)) > n/2 for x in list(product(permutations(a, n), permutations(b, n)))) / n**2))
0