#include<bits/stdc++.h>
using namespace std;
int main()
{
long long en;cin>>en;
float a=0.4463,b=0.4663,c=0.5663;
long long x,y,z;
float cost;
if(en<=150)
x=en;
y=0;
z=0;
if(150<en)
{
if(en<=400)
{
x=150;
y=en-150;
z=0;
}
}
if(en>400)
{
x=150;
y=400-150;
z=en-400;
}
cost=(a*x)+(b*y)+(c*z);
printf("%.1f",cost);
return 0;
}