Preparing NOJ
On a infinite plane,you are on the (0,0) at the beginning.
You have to move to (x,y).But you can only move by the give K ways.
I want you to give me the least steps you need to move to the destination.
For example
If you have to go to (3,1) and you have 3 ways to move: (-1,1) (1,0)(3,1).you only need one (3,1) move to get to the destination.
There are more than one case in a single input.
I promise that you can get to the destination.
1
1 1 1
1 1
1
本题由旧版NOJ导入,来源:2E