#include<iostream>
#include<cmath>
#include<string>
#include<iomanip>
using namespace std;
class customer{
    protected:
    string itemType;
    float weight,price;
    public:
    void display(){
        cin>>itemType>>weight>>price;
        if(itemType!="fruit"&&itemType!="vegetable"){
            cout<<"Invalid input";
        }
        else{
            cout<<weight*price;

        }
    }
};
int main(){
    Market m;
    tm.display();
    return 0;
}