結果

問題 No.1281 Cigarette Distribution
ユーザー penguinman
提出日時 2020-11-07 01:47:53
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
RE  
実行時間 -
コード長 176 bytes
コンパイル時間 223 ms
コンパイル使用メモリ 12,288 KB
実行使用メモリ 10,624 KB
最終ジャッジ日時 2024-07-22 14:03:13
合計ジャッジ時間 2,255 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other RE * 23
権限があれば一括ダウンロードができます

ソースコード

diff #

N=int(input())
M=int(input())
mod=int(1e9+7)
for i in range(M):
    j=i+1
    ans=pow(N//j+1,N%j,mod)*pow(N//j,j-N%j,mod)
    ans%=mod
    if j==N:
        ans=0
    print(ans)
0