Question: 1. Write a C# statement to create an array named numList to hold the 5 numeric scores. Here is the example of declared an array

1.

Write a C# statement to create an array named numList to hold the 5 numeric scores.

Here is the example of declared an array doubleList which stores 10 double values.

double[] doubleList = new double[10];

or

const int SIZE = 10;

double[] doubleList = new double[SIZE];

2. Write a C# statement to declare an array of characters named alpha which stores 26 letters ('A' to 'Z')

3.

The arrays list1 and list2 each hold 100 integer elements. Write C# code that copies the values in list1 to list2

(Instead of using Array.Copy() method, design your own copy method using the for loop. Here is the for loop to achieve the copying.)

for (int i = 0; i < 100; i++)

{

//write your code to copy value from list1 to list2

}

4.

Write a for loop to add each array element and store the total into variable sum.

The variable declarations are as follows:

int[] list = new int[10];

int sum = 0;

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!