410802: GYM104118 D Domination Devil

Memory Limit:256 MB Time Limit:6 S
Judge Style:Text Compare Creator:
Submit:0 Solved:0

Description

D. Domination Deviltime limit per test6 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputExamplesInput
4 1
Output
6
Input
4 2
Output
30
Input
200000 1
Output
1581480553
Input
200000 100000
Output
1212906613

加入题单

上一题 下一题 算法标签: