fun21.density - [2021 Fun]Density o' bullseye


Version: v1

Submit Problemset 1000ms / 262144 KB
Difficulty:1.0x

Statement

Suika can control the density of everything. Can your program do the same thing?

Suika

If a program runs for $T$ ms and its memory usage is $M$ KB, let's define the density of the program to be $D=\frac{M}{T+1}$

Your task is to write a program so that its density is as close to the number given as possible.

Task

Write a program that:

Input

$D$, a double with at most 3 digits after decimal point, $8\leq D\leq 262,000$

Output

A single integer.

Example

[In]
667
[Output]
123
[Explain]
Suppose it runs for 15ms, memory usage is 10000KB, then its density is 666.67 which is a bullseye.

Scoring

There are 20 testcases.

Assume your program's density is $D'$ and $x=|D'-D|$. The score is defined as follow for each testcase:

XRankScore
<=1Bullseye100
<=10SSS25
<=20SS20
<=30S10
<=100A8
<=500B6
<=1000C4
<=262000D1
>262000D++250

Submit