1D Arrays 6. In the following code line: int [] deck new int [52] (Each question
ID: 3751012 • Letter: 1
Question
1D Arrays 6. In the following code line: int [] deck new int [52] (Each question is 2 points) LIST /ANSWER the following: .What does the above code line do? . What is the name of the array (array reference variable)? What is the type of the data elements of the array? What are the initial values of the data elements of the array? What is the length of the array? Write down here the part of the line, where the array is declared: . Write down here the part of the line, where the array is created Write down here the part of the line, where the created array is assigned to the declared array reference variable: Write down here the reference' to the 1t array element and assign to it 5: What is the index of the referenced 1t array element? Write down, here, the reference to the 3d array element and assign to it the sum of the 1t and the 2d elements of the array: Declare a double 1D array with the name myList, create an array of 50 elements, and assign it to the declared array myList. Do it: All in one line. Answer: 7. Recall, you use an index variable to reference a particular array element valueExplanation / Answer
Here,The givne code is,
int[] deck = new int[52];
Here it is an declaration of the array in java with deck of 52 cards as well.
7Q(Ans).
double[] myList = new double[50];
Here,above one done in a single line.
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.