favorite We need a little bit of your help to keep things running, click on this banner to learn more

Mobile tariff "Cents"

Mobile tariff "Cents"

Peter using a mobile data plan "Cents". Each outbound call is charged as follows: 1 cent per connection plus the first minute of conversation costs 64 cents, and for each subsequent minute - two times cheaper than the previous one, but not cheaper than 1 cent. Minute tariffication, that is, even if Peter did not use all the time last minute, it is paid in full. I find the price in cents phone call duration N seconds.


The file recorded a positive integer N (N = 1..2·109).


Call costs (in cents).

Time limit 1 second
Memory limit 64 MiB
Input example #1
Output example #1
Author Matviychuk S.V.
Source Stage III All-Ukrainian School Olympiad 2010-2011, Round 1, Zhytomyr