Question: Using the following declaration: int [ ] anArray = {34, 55, 67, 89, 99}; What would be the result of each of the following output
Using the following declaration:
int [ ] anArray = {34, 55, 67, 89, 99};
What would be the result of each of the following output statements?
a. Console.WriteLine(anArray.Length);
b. Console.WriteLine(anArray[2]);
c. Console.WriteLine(anArray[anArray.Length -2]);
d. Console.WriteLine(anArray[2 + 1] * anArray[0]);
e. Console.WriteLine(anArray[1] + 100);
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
