Untitled

Run Settings
LanguageJava
Language Version
Run Command
import java.util.Scanner; class Pizza { public static void main(String[] args) { //System.out.println("Hello people 123"); int labourcost = 1; double storecost = 1.50; double materialcost; double totalcost; Scanner Scan = new Scanner(System.in); System.out.println (" Please Select Pizza Size: (Small = 6 Inch, Medium = 8 Inch, Large = 10 Inch, X-Large = 12 Inch) "); String Size = Scan.nextLine(); //System.out.println ("Selected Size = " + Size); int SizeInt = Integer.parseInt(Size); materialcost = 0.5 * SizeInt; System.out.println ("How many Pizzas required ?"); String Quantity = Scan.nextLine(); //System.out.println ("Selected number = " + Quantity); int QuantityInt = Integer.parseInt(Quantity); //System.out.println (QuantityInt); labourcost = 1 * QuantityInt; storecost = 1.5 * QuantityInt; totalcost = (labourcost + storecost + materialcost) * QuantityInt; if (SizeInt == 6) System.out.println ("Size chosen : Small"); else if (SizeInt == 8) System.out.println ("Size chosen : Medium"); else if (SizeInt == 10) System.out.println ("Size chosen : Large"); else if (SizeInt == 12) System.out.println ("Size chosen : X-large"); System.out.println ("Number of pizzas: " + QuantityInt); System.out.println ("Labour Cost: " + QuantityInt); System.out.println ("Store cost: " + storecost); System.out.println ("Material cost: " + QuantityInt * SizeInt); System.out.println ("Total cost:" + QuantityInt + storecost + SizeInt); System.out.println ("_ __ _ __________ _ "); System.out.println ("| '_ \\| |_ /_ / _` | "); System.out.println ("| |_) | |/ / / / (_| | "); System.out.println ("| .__/|_/___/___\\__,_| "); System.out.println ("| | By Taranjit "); System.out.println ("|_| "); } }
Editor Settings
Theme
Key bindings
Full width
Lines