ENG
RUS
Timus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board
Discussion of Problem
2025
. Line Fighting
Hint and some tests
Posted by
mberdyshev
23 Dec 2015 22:31
maximize amount of teams, but minimize max amount of fighters in a team.
For example, if n=9, k=5, you should make 5 teams this way: (2, 2, 2, 2, 1)
Tests
:
Input:
3
7 4
9 4
12 5
Output:
18
30
57
Edited by author 23.12.2015 22:42
© 2000–2024
Timus Online Judge Team
. All rights reserved.