#include <string>
#include <iostream>

using namespace std;

class priceName
{
public:
    string getName()
    {
        return name;
    }
    double getPrice()
    {
        return price;
    }
    void setName(string i)
    {
        this->name=i;
    }
    void setPrice(double i)
    {
        this->price=i;
    }
private:
    string name;
    double price;
};

class iFood
{
public:
    iFood(string i, double j)
    {
        pn.setName(i);
        pn.setPrice(j);
    }
    void show()
    {
        cout<<pn.getName()<<" : "<<pn.getPrice()<<endl;
    }
private:
    priceName pn;
};

class iDrink
{
public:
    iDrink(string i, double j)
    {
        pn.setName(i);
        pn.setPrice(j);
    }
    void show()
    {
        cout<<pn.getName()<<" : "<<pn.getPrice()<<endl;
    }
private:
    priceName pn;
};

int main(void)
{

    iFood food("apple",0.99);
    iDrink drink("coke",1.99);

    food.show();
    drink.show();

    return(0);
}
