Question
IN C# simply create the arrays and loops to solve the problem. Your job is to create a simple program for a company that sells
IN C#
simply create the arrays and loops to solve the problem. Your job is to create a simple program for a company that sells BBQ sauce. Follow the instructions below.
Directions
Begin an empty console application.
Create an array of strings to hold the names of the types of sauce that the company sells:
Eastern Carolina, Western Carolina, Kansas City, SC Mustard, and Texas.
Create an empty array to store the price of each type of sauce.
Create an empty array to store the number of jars (of each sauce) that the company sold
last year.
Write a loop that asks the user to enter the information to store in the price and number
of jars array. Note: You can do this in one loop.
Output all arrays using the following format: Name, Price, and Number of Jars. (Each line
should display all three pieces of information for each type of sauce).
Write a loop to find the most popular sauce that the company sells. Output the price and
the name of this sauce, along with the number of jars that were sold.
Allow the user to search the array of names for a certain type of sauce. Note: you will need
to ask the user what he wants to look for (you can assume the user knows the names).
Display the price of the sauce that the user entered.
Sort and display the types of sauce by popularity, from the most to least popular.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started