Write a program named TestScoreList that accepts eight int values representing student test scores. Display each of the values along with a message that indicates how far it is from the average.

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

C# Question 2. I keep getting these errors and not sure what they mean. Help of input and output would be appreciated! 

CHAPTER 6 Using Arrays
2. Write a program named TestScoreList that accepts eight int values representing
far it is from the average.
student test scores. Display each of the values along with a message that indicates how
3.
4.
5.
6.
Write a program named TemperaturesComparison that allows a user to input five
daily Fahrenheit temperatures that must range from -30 to 130; if a temperature
is out of range, require the user to reenter it. If no temperature is lower than any
previous one, display a message Getting warmer. If every temperature is lower than
the previous one, display a message Getting cooler. If the temperatures are not entered
in either ascending or descending order, display a message It's a mixed bag. Finally,
display the temperatures in the order they were entered, and then display the average
of the temperatures.
Write a program named CheckZips that is used by a package delivery service to check
delivery areas. The program contains an array that holds the 10 zip codes of areas to
which the company makes deliveries. Prompt a user to enter a zip code, and display a
message indicating whether the zip code is in the company's delivery area.
Write a program called DeliveryCharges for the package delivery service in Exercise 4.
The program should again use an array that holds the 10 zip codes of areas to which
the company makes deliveries. Create a parallel array containing 10 delivery charges
that differ for each zip code. Prompt a user to enter a zip code, and then display either
the company does not deliver to the requested zip code.
a message indicating the price of delivery to that zip code or a message indicating that
total cost of the call.
The Chat-A-While phone company provides service to six area codes and charges
the per-minute rates for phone calls shown in Figure 6-25. Write a program named
ChatAWhile that stores the area codes and rates in parallel arrays and allows a user
to enter an area code and the length of time for a call in minutes, and then display the
Per-Minute Rate ($)
Transcribed Image Text:CHAPTER 6 Using Arrays 2. Write a program named TestScoreList that accepts eight int values representing far it is from the average. student test scores. Display each of the values along with a message that indicates how 3. 4. 5. 6. Write a program named TemperaturesComparison that allows a user to input five daily Fahrenheit temperatures that must range from -30 to 130; if a temperature is out of range, require the user to reenter it. If no temperature is lower than any previous one, display a message Getting warmer. If every temperature is lower than the previous one, display a message Getting cooler. If the temperatures are not entered in either ascending or descending order, display a message It's a mixed bag. Finally, display the temperatures in the order they were entered, and then display the average of the temperatures. Write a program named CheckZips that is used by a package delivery service to check delivery areas. The program contains an array that holds the 10 zip codes of areas to which the company makes deliveries. Prompt a user to enter a zip code, and display a message indicating whether the zip code is in the company's delivery area. Write a program called DeliveryCharges for the package delivery service in Exercise 4. The program should again use an array that holds the 10 zip codes of areas to which the company makes deliveries. Create a parallel array containing 10 delivery charges that differ for each zip code. Prompt a user to enter a zip code, and then display either the company does not deliver to the requested zip code. a message indicating the price of delivery to that zip code or a message indicating that total cost of the call. The Chat-A-While phone company provides service to six area codes and charges the per-minute rates for phone calls shown in Figure 6-25. Write a program named ChatAWhile that stores the area codes and rates in parallel arrays and allows a user to enter an area code and the length of time for a call in minutes, and then display the Per-Minute Rate ($)
eeks ago
Toolbox
File Edit View Git Project Build Debug Test Analyze
·口
-882.C
7
Program.cs* X What's New?
C# TestScoreList
40
41
42
43
44
45
46
47
48 1
49
50
51
52
53
54
55
56
68 %
caps Lock
57
58
59
60
61
62
63
64
65
Error List
Entire Solution
Code
X CS0021
CS0201
66°F
Sunny
esc
LT
}
}
Error List Output
Ready
}
{
// Display values and distance
for (i = 0; i < arraySize; ++i)
{
2
Debug Any CPU
}
// Calculate average and display it (cast integers as double for 2 decimal precisiom)
average = (double) total / tdouble)arraysize;
WriteLine("********
********);
WriteLine($"\nAverage test score =(average:F2}\n");
?
Y
average;
1 retarence
private static object ReadLine()
A0
↑
↓
Write($"Score {1+ 1} of {arraysize}: ");
(new int[arraySize]) [1] = Convert.ToInt32(ReadLine());
total += (new int [arraysize]) [i];
X2 Errors
D
A0 Warnings
Write("{0,8] [1,-4} {2,-8}", "Score" + (1 + 1) + " = ", testScores [1],
Dovydas
2.9M views • 4 month
Tools Extensions Window Help Search (Ctrl+Q)
#3
TestScoreList.Program
Start -
D
P
0 Messages
T
L
Description
Only assignment, call, increment, decrement, await, and new object expressions can be
used as a statement
Cannot apply indexing with [] to an expression of type 'object'
Build
+
W
IntelliSense
"
+ distance.ToString("F2") + " from average\n");
Project
TestScoreList
TestScoreList
?
G H
习习习
Main(string[] args, object testScores)
File
Program.cs
Program.cs
J
=
Ln: 58
58
*Ch: 25
TestScoreList
Search Error List
Line Suppression State
Active
59 Active
SPC
CRLF
4x
P
4
HE
#
↑ Add to Source Control
▶
Soluti
Proper
Transcribed Image Text:eeks ago Toolbox File Edit View Git Project Build Debug Test Analyze ·口 -882.C 7 Program.cs* X What's New? C# TestScoreList 40 41 42 43 44 45 46 47 48 1 49 50 51 52 53 54 55 56 68 % caps Lock 57 58 59 60 61 62 63 64 65 Error List Entire Solution Code X CS0021 CS0201 66°F Sunny esc LT } } Error List Output Ready } { // Display values and distance for (i = 0; i < arraySize; ++i) { 2 Debug Any CPU } // Calculate average and display it (cast integers as double for 2 decimal precisiom) average = (double) total / tdouble)arraysize; WriteLine("******** ********); WriteLine($"\nAverage test score =(average:F2}\n"); ? Y average; 1 retarence private static object ReadLine() A0 ↑ ↓ Write($"Score {1+ 1} of {arraysize}: "); (new int[arraySize]) [1] = Convert.ToInt32(ReadLine()); total += (new int [arraysize]) [i]; X2 Errors D A0 Warnings Write("{0,8] [1,-4} {2,-8}", "Score" + (1 + 1) + " = ", testScores [1], Dovydas 2.9M views • 4 month Tools Extensions Window Help Search (Ctrl+Q) #3 TestScoreList.Program Start - D P 0 Messages T L Description Only assignment, call, increment, decrement, await, and new object expressions can be used as a statement Cannot apply indexing with [] to an expression of type 'object' Build + W IntelliSense " + distance.ToString("F2") + " from average\n"); Project TestScoreList TestScoreList ? G H 习习习 Main(string[] args, object testScores) File Program.cs Program.cs J = Ln: 58 58 *Ch: 25 TestScoreList Search Error List Line Suppression State Active 59 Active SPC CRLF 4x P 4 HE # ↑ Add to Source Control ▶ Soluti Proper
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps with 2 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY