subject

Quarter Final Sample Test: 1 Greedy puppy
Tuzik is a little dog. But despite the fact he is still a puppy he already knows about the pretty things that coins are,
He knows that for every coin he can get very tasty bone from his master. He believes that some day he will find a
treasure and have loads of bones.
And finally he found something interesting. A wooden chest containing N coins! But as you should remember,
Tuzik is just a little dog, and so he can't open it by himself. Actually, the only thing he can really do is barking. He
can use his barking to attract nearby people and seek their help. He can set the loudness of his barking very
precisely, and therefore you can assume that he can choose to call any number of people from a minimum of 1. to a
maximum of
When people come and open the chest they divide all the coins between them in such a way that everyone will get
the same amount of coins and this amount is maximal possible. If some coins are not used they will leave it on the
ground and Tuzik will take them after they go away. Since Tuzik is clearly not a fool, he understands that his profit
depends on the number of people he will call. While Tuzik works on his barking, you have to find the maximum
possible number of coins he can get.
Input
The first line of the input contains an integer T denoting the number of test cases. Each of next T lines contains 2
space-separated integers: N and K, for this test case.​

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 21:30
Nathan wants to create multiple worksheet containing common formatting styles for his team members. which file extension him to save these worksheets? nathan to create multiple worksheets with common styles. he needs to save them with the extension.
Answers: 1
question
Computers and Technology, 23.06.2019 17:00
The more powerful, 60 volt cables and the main power shut-off on an hev are both colored orange.
Answers: 1
question
Computers and Technology, 24.06.2019 08:00
Arah has entered data about football players from team a and team b in a worksheet. she enters names of players from team a with details about each player in different columns of the worksheet. similarly, she enters details of all the players from team b. which option will her view the data for team a and team b in two separate sections after printing? a. page break view b. freeze pane view c. split screen view d. full screen view e. zoom out view
Answers: 1
question
Computers and Technology, 24.06.2019 10:00
In which view can you see speaker notes?
Answers: 1
You know the right answer?
Quarter Final Sample Test: 1 Greedy puppy
Tuzik is a little dog. But despite the fact he is st...
Questions
question
Spanish, 05.07.2019 15:00
Questions on the website: 13722367