int main()
{
    double f = 0.0;
    while(1)
    {
        scanf("%lf",&f);
        if(f >= 1 && f <= 100000)
            break;
    }
    double c = 5.0/9*(f-32);
    printf("%.3lf",c);
}