Bluebook

Pop Explosion

The population of a certain country has been increasing at an average rate of P percent each year. Assuming that the population was A in year Y, write a program that finds the year in which the population will reach B if the grown pattern continues.

Input, Output

The order of input will be P A Y B. Output should be in whole numbers (i.e. no decimals)

Sample Input

5.5 24000000 1980 100000000

Sample Output

2007

All Submissions
Best Solutions


Point Value: 3
Time Limit: 2.00s
Memory Limit: 16M
Added: Oct 22, 2008

Languages Allowed:
C++03, PAS, C, HASK, ASM, RUBY, PYTH2, JAVA, PHP, SCM, CAML, PERL, C#, C++11, PYTH3

Comments (Search)


Was browsing through easy questions and saw this... Wierd...

In the textbook, there is not sample output. Perhaps that's why?

Still though, it is odd to have it up there with nothing below.

Blame Toby (probably). Anyways, the output for the sample case has been added.