Instructions ChiliToGo.java + >- Terminal 1 import java.util.Scanner; 2 class ChiliToGo { sandbox $ 0 The Huntington Boys and Girls Club is conducting a fundraiser by selling chili dinners to go. The price is public static void main(String[] args) { Lalal // Write your code here 4 $7.00 for an adult meal and $4.00 for a child's meal. 5 </> 6 } Write a program that accepts the number of adult meals ordered and then children's meals ordered. Display the total money collected for adult meals, children's meals, 7. and all meals. An example of the program is shown below: Enter number of adult meals ordered >> 10 Enter number of child neals ordered >> 5 10 adult neals were ordered at 7.0 each. Total is 70.0 5 chtld meals were ordered at 4.0 each. Total is 20.0 Grand total for all meals is 90.0 Grading Write your Java code in the area on the right. Use the Run button to compile and run the code. Clicking the Run Checks button will run pre-configured tests against your code to calculate a grade. Once you are happy with your results, click the Submit button to record your score.

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter8: Arrays
Section: Chapter Questions
Problem 1DE
icon
Related questions
Question
Instructions
ChiliToGo.java
>- Terminal
1 import java.util.Scanner;
sandbox $ 0
2 class ChiliToGo {
The Huntington Boys and Girls Club is conducting a
3
public static void main(String[] args) {
Llal
fundraiser by selling chili dinners to go. The price is
// Write your code here
4
$7.00 for an adult meal and $4.00 for a child's meal.
5
}
</>
Write a program that accepts the number of adult meals
6 }
7
ordered and then children's meals ordered. Display the
total money collected for adult meals, children's meals,
and all meals.
An example of the program is shown below:
Enter number of adult meals ordered >> 10
Enter number of child meals ordered >> 5
10 adult meals were ordered at 7.0 each.
Total is 70.0
5 child meals were ordered at 4.0 each.
Total is 20.0
Grand total for all meals is 90.0
Grading
Write your Java code in the area on the right. Use the
Run button to compile and run the code. Clicking the
Run Checks button will run pre-configured tests against
your code to calculate a grade.
Once you are happy with your results, click the Submit
button to record your score.
Transcribed Image Text:Instructions ChiliToGo.java >- Terminal 1 import java.util.Scanner; sandbox $ 0 2 class ChiliToGo { The Huntington Boys and Girls Club is conducting a 3 public static void main(String[] args) { Llal fundraiser by selling chili dinners to go. The price is // Write your code here 4 $7.00 for an adult meal and $4.00 for a child's meal. 5 } </> Write a program that accepts the number of adult meals 6 } 7 ordered and then children's meals ordered. Display the total money collected for adult meals, children's meals, and all meals. An example of the program is shown below: Enter number of adult meals ordered >> 10 Enter number of child meals ordered >> 5 10 adult meals were ordered at 7.0 each. Total is 70.0 5 child meals were ordered at 4.0 each. Total is 20.0 Grand total for all meals is 90.0 Grading Write your Java code in the area on the right. Use the Run button to compile and run the code. Clicking the Run Checks button will run pre-configured tests against your code to calculate a grade. Once you are happy with your results, click the Submit button to record your score.
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 4 steps with 2 images

Blurred answer
Knowledge Booster
Data members
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT