結果

問題 No.129 お年玉(2)
ユーザー ktshun
提出日時 2015-06-11 15:39:56
言語 Python2
(2.7.18)
結果
WA  
実行時間 -
コード長 216 bytes
コンパイル時間 430 ms
コンパイル使用メモリ 6,912 KB
実行使用メモリ 6,656 KB
最終ジャッジ日時 2024-07-06 15:37:18
合計ジャッジ時間 2,870 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 5 WA * 41
権限があれば一括ダウンロードができます

ソースコード

diff #

# -*- coding:utf-8 -*-

import math

if __name__ == "__main__":
	n = input()
	m = input()
	n /= 1000
	n %= m
	if n == 0:
		print 1
		exit()
	else:
		print math.factorial(m) / (math.factorial(n) * math.factorial(m-n))
0