KiwiJelly5158 KiwiJelly5158
  • 24-12-2019
  • Computers and Technology
contestada

In a single statement: declare, create and initialize an array named a of ten elements of type int with the values of the elements (starting with the first) set to 10, 20, ..., 100 respectively.

Respuesta :

Debel
Debel Debel
  • 25-12-2019

Answer:

int[] a = {10, 20, 30, 40, 50, 60, 70, 80, 90, 100};

Explanation:

//written in java

The left side int[] a Declare a variable(a) which is of type Integer array(int[]).

The equal sign(=) assign the right side to the left side.

The right side initialize the integer array(a) with ten element.

Answer Link

Otras preguntas

Taiwan is located south of South Korea.
what is the value of x in the equation 2x+3y=36 when y=6
Who is Chinua Achebe?
What were the four natural resources needed for British industrialization?
Describe the solutions of 6+y <10 in words
Solve for both systems: x + 5y = 7 and x + 3y = 1
Why did Napoleon have trouble fighting the enemy forces in the Peninsular War?
A periodic wave has a fixed pattern that is repeated. What is one completion of the wave pattern called? a) period b) frequency c) amplitude d)cycle e) phase
Do the events surrounding the Election of 2000 justify changes to the Electoral College? Explain why you think it does or why you think it does not in a well-wr
The prices of stocks have been going up for the past two weeks. To economists, this change in price is considered a _____. a. lagging indicator b. coincident in