create a class named pizzaSolutionclass Pizza String toppin

create a class named pizza

Solution

class Pizza
{
String toppings;
String typeOfPizza;
double price;
String getToppings()
{
return toppings;
}
void setToppings(String a)
{
toppings=a;
}
int getTypeOfPizza()
{
return typeOfPizza;
}
void setTypeOfPizza(String t)
{
typeOfPizza =t;
}
double getPrice()
{
return price;
}
void setPrice(double p)
{
price=p;
}
Pizza (String typeOfPizza)

{

System.out.println (typeOfPizza);

}

}

create a class named pizzaSolutionclass Pizza { String toppings; String typeOfPizza; double price; String getToppings() { return toppings; } void setToppings(St

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site