Question
Requirements: - In C# - To successfully complete these tasks, USE ARRAYS where needed. DO NOT USE ANY OTHER COLLECTION such as Lists, ArrayLists, Dictionaries,
Requirements:
- In C#
- To successfully complete these tasks, USE ARRAYS where needed. DO NOT USE ANY OTHER COLLECTION such as Lists, ArrayLists, Dictionaries, Queues, Stacks, Linked Lists, etc.
1) Write a program that reads data into an array of type int. Valid values are from 0 to 10. Your program should display how many valid values were inputted as well as the number of invalid entries. Output a list of distinct valid entries and a count of how many times that entry occured. Use the following test data:
1 7 2 4 2 3 8 4 6 4 4 7
2) The ION Realty Sales Corporation would like to have a listing of their sales over the past few months. Write a program that accepts any number of monthly sales amounts. Display the total of the values. Display a report showing each original value entered and the percentage that value contributes to the total. You may prompt the user for the number of values to be inputted.
3) Write a temperature application. Your solution should be a two class application that has a one-dimensional array as a data member. The array stores temperatures for any given week. Provide constructors for instantiating the class and methods to return the highest temperature, lowest temperature, average temperature and the average temperature excluding the lowest temperature. Provide a method that accepts as an argument a temperature and returns the number of days the temperatures were below that value. Override the ToString() method to return a listing of all the temperatures in three column format and the temperature range for the given week. Write a second class to test your class.
4) Create three arrays of type double. Do a compile-time initialization and place different values in two of the arrays. Write a program to store the product of the two arrays in the third array. Produce output that shows the contents of each of the arrays on one line.
5) Create an integer array that holds values:
1, 50, 35, 700, 15, 23, 2, 4, 6, 5, 7, 8, 19, 3, 16500, 7401
a) Display the array on one line
b) Display the mean of all numbers
c) Display the mean of all numbers less than 50
d) Display the reverse of the array
e) Sort and display the array
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