This preview shows page 1. Sign up to view the full content.
Unformatted text preview: ing the rear wheel always spins faster than the pedals. Your input will consist of multiple data sets, one per line. Each set will contain a single real number greater than one and less than six indicating the number of times the rear wheel should spin for each revolution of the pedals. Your output for each data set should be two integers on a single line. The first integer is the number of gears on the pedal gearwheel and the second integer is the number of gears on the rear wheel gearwheel, such that the ratio between these two values is the closest poss-ible to the given input ratio. If multiple possible combinations of gears yield the same ratio, select the pair with the smallest total number of gears. p Sample input: 3 3.04 2.41 Sample output: 48 16 76 25 70 29...
View Full Document
- Spring '11