Use the selectionSort method presented in this section to answer this question. Assume list is {3.1, 3.1, 2.5, 6.4, 2.1}, what is the content of list after the first iteration of the outer loop in the method?
A. 2.5, 3.1, 3.1, 6.4, 2.1
B. 3.1, 3.1, 2.5, 2.1, 6.4
C. 3.1, 3.1, 2.5, 6.4, 2.1
D. 2.1, 3.1, 2.5, 6.4, 3.1
查看答案
Which of the following are valid array declarations?
A. char[] charArray = new char[26];
B. int[] words = new words[10];
C. double[3] nums = {3.5, 35.1, 32.0};
D. char[] charArray = "Computer Science";
In the following code, what is the printout for list2? public class Test {public static void main(String[] args) {int[] list1 = {1, 2, 3};int[] list2 = {1, 2, 3};list2 = list1;list1[0] = 0; list1[1] = 1; list2[2] = 2; for (int i = 0; i < list2.length; i++)System.out.print(list2[i] + " ");} }
A. 0 1 3
B. 1 1 1
C. 0 1 2
D. 1 2 3
It is the best way to answer the phone call within _____ .
A. the 2nd ring
B. the 3ird ring
C. the 6th ring
D. 60 seconds
We would like to _____ you a discount _____ 5%, if your order exceeds USD$1,000.
A. give/of
B. allow/of
C. allow/to
D. give/to