Welcome![Sign In][Sign Up]
Location:
Downloads SourceCode Mathimatics-Numerical algorithms Data structs
Title: zhuiyezhu Download
 Description: Animal world always makes a cheetah run with speed and beauty. That day, the cheetah eye on a wild boar, and now To catch the color because the cheetah is well protected, so the boar did not find cheetah. Cheetah and wild boar in the same line, Their coordinates are x and y, x is less than or equal y,. Now there are two cheetah run method: 1. Running a grid, that is, from x to x 1 or x-1 2. Running twice, that is, from x to 2* x. Now find at least a few steps you catch wild boar. ★ data input Line 1 input is given two positive integers x, y (0 <x <= y <= 100000), respectively, the coordinates of the cheetah and wild boar coordinates. ★ data output Only one line of output, given the least number of steps. Input Example Example Output 5 17 4
 To Search:
File list (Check if you may need any files):
liebao and yezhu.cpp
    

CodeBus www.codebus.net