#include<bits/stdc++.h>
using namespace std;
int main(){
	int n;
	float h=0;
	cin>>n;
	if(n<10){
		h=n*1.8;
	}
	else if(19>n&&n>10){
		h=n*1.5;
	}  
	else if(29>n&&n>20){
		h=n*1.2;
	} 
	else if(n>=30){
		h=n*1.0;
	} 
		printf("%.1f",h);
	return 0;
}
/**************************************************************
	Problem: 1304
	User: fuhoubin
	Language: C++
	Result: Wrong Answer
****************************************************************/