#include<stdio.h>
#include<math.h>
int main(){
    int choice;
    float distance,result;
    scanf("%d", &choice);
    scanf("%f", &distance);
    if(choice != 1 && choice != 2);{
        printf("Invalid input\n");
    }else 
    if (distance < 0){
        printf("Invalid input");
    }else{
        if(choice == 1){
            result = distance*0.621371;
        }
    }else {
        result = distance*1.60934;
    }
    printf("%.2f\n",result);
return 0;
}