Question
In c# Write an application that creates an array which can store distances to different historical sights. Create a method to fill the array. Prompt
In c#
Write an application that creates an array which can store distances to different historical sights.
Create a method to fill the array.
Prompt the user to enter the distances
Use the following test data:
2.25 1.5 1.80 7.25 8.25
Display a heading that includes your name. For example your heading might read: Software developed by: (your name)
Create a method that uses a for loop and calculates and returns the sum of the values. Include an appropriate label with the calculated value
Create a method that display all distances less than 5.0. Include an appropriate heading before the numbers are displayed.
Create a method that uses a foreach loop to calculate and display the average of the values. Include an appropriate label with the calculated value
Create a method that displays all values that are higher than the calculated average. Again, include an appropriate label with the calculated value.
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