Exam 8: Arrays and the Arraylist Class
Exam 1: Introduction to Computers and Java42 Questions
Exam 2: Java Fundamentals53 Questions
Exam 3: Decision Structures52 Questions
Exam 4: Loops and Files48 Questions
Exam 5: Methods50 Questions
Exam 6: A First Look at Classes49 Questions
Exam 7: A First Look at Gui Applications49 Questions
Exam 8: Arrays and the Arraylist Class52 Questions
Exam 9: A Second Look at Classes and Objects40 Questions
Exam 10: Text Processing and More About Wrapper Classes49 Questions
Exam 11: Inheritance49 Questions
Exam 12: Exceptions and Advanced File Io46 Questions
Exam 13: Advanced Gui Applications46 Questions
Exam 14: Applets and More39 Questions
Exam 15: Recursion34 Questions
Exam 16: Sorting, Searching, and Algorithm Analysis46 Questions
Exam 17: Generics50 Questions
Exam 18: Collections50 Questions
Exam 19: Array-Based Lists20 Questions
Exam 20: Linked Lists36 Questions
Exam 21: Stacks and Queues36 Questions
Exam 22: Binary Trees, Avl Trees, and Priority Queues45 Questions
Select questions type
What will be the value of x[1] after the following code is executed? int[] x = {22,33,44};
ArrayProcess(x);
…
Public static void arrayProcess(int[] a)
{
For(int k = 0;k < 3;k++)
{
A[k] = a[k] + 5;
}
}
(Multiple Choice)
4.8/5
(33)
Given the following two-dimensional array declaration,which statement is true? int [][] numbers = new int [6] [9];
(Multiple Choice)
4.7/5
(39)
Objects in an array are accessed with subscripts,just like any other data type in an array.
(True/False)
4.9/5
(34)
You can use this ArrayList class method to insert an item at a specific location in an ArrayList.
(Multiple Choice)
4.8/5
(40)
What would be the results after the following code was executed? int[] x = {23,55,83,19};
Int[] y = {36,78,12,24};
For(int a = 0;a < x.length;a++)
{
X[a] = y[a];
Y[a] = x[a];
}
(Multiple Choice)
4.8/5
(39)
What will be returned from the following method? public static float[] getValue(int x)
(Multiple Choice)
4.7/5
(38)
Which of the following for loops is valid,given the following declaration? String[] names = {"abc","def","ghi","jkl"};
(Multiple Choice)
4.9/5
(28)
This ArrayList class method is used to insert an item into an ArrayList.
(Multiple Choice)
4.8/5
(43)
What would be the results of the following code? final int SIZE = 25;
Int[] array1 = new int[SIZE];
… // Code that will put values in array1
Int value = 0;
For (int a = 0;a < = array1.length;a++)
{
Value += array1[a];
}
(Multiple Choice)
4.7/5
(44)
Showing 41 - 52 of 52
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)