#include <stdio.h> 
using namespace std;
int main() {
    float weight;  
    float fee;   
    scanf("%f", &weight);
    if (weight <= 10) {
        fee = weight * 1.5;
    } else {
        fee = 10 * 1.5 + (weight - 10) * 2.5;
    }
    printf("%.2f\n", fee);

    return 0;
}
/**************************************************************
	Problem: 1052
	User: fuhoubin
	Language: C++
	Result: Wrong Answer
****************************************************************/