java programing homework help!
i really need help with my homework
this is what i have to do
You are buying a picnic lunch to share with friends in the park. Write, compile, and test a Java class that will 1) ask for a budget amount 2) display the cost of each item for a lunch for three and 3) calculate and display the total price of all the items and determine and display whether you have exceeded your budget.
Lunch items will consist of apples, cheese, and bread. Use six class variables of the appropriate data type to hold the price (cost) and amount (quantity) of each item as indicated in the following table:
You will need additional class variables to hold the budget and total amounts.
Your program will ask the user for the budget amount through an input dialog box and then display the results in message dialog boxes. Hint: it might be easier to first create a String variable to hold all or part of the second parameter to the JOptionPane.showMessageDialog() method.
Your output should resemble the pictures below:
this is what i have so far, i need a little help with it. thanks!
public class Lunch
public static void main(String args)
(null,"Enter your budget", "Budget", JOptionPane.QUESTION_MESSAGE);
double apple = .25;
double cheese = 3.99;
double bread = 1.19;
JOptionPane.showMessageDialog(null, "Lunch consists of:3 apples at $0.25 a piece 0.5lb of cheese at $3.99 a pound;1 loaf(s) of bread at
total = apple + cheese + bread;
JOptionPane.showMessageDialog(null, "The total is: "