Show the output of the following code:
```
String[] array = {"red", "green", "blue"};
ArrayList
list.add(0, "red");
System.out.println(list);
```
a. ["red", "green", "blue", "red"]
b. ["red", "green", "blue"]
c. ["red", "red", "green", "blue"]
d. ["red", "green", "red", "blue"]
c. ["red", "red", "green", "blue"]
You might also like to view...
Answer the following statements true (T) or false (F)
1) An algorithm is a procedure for solving a problem in terms of the actions to execute and the order in which these actions execute. 2) A set of statements contained within a pair of parentheses is called a block. 3) A selection statement specifies that an action is to be repeated while some condition re-mains true. 4) A nested control statement appears in the body of another control statement. 5) C# provides the arithmetic compound assignment operators +=, -=, *=, /= and %= for abbreviating assignment expressions.
A(n) ________ program helps the user perform specific tasks such as word processing
A) operating system B) compiler C) networking D) application
WordArt is a movable container for both graphics and text
Indicate whether the statement is true or false
How is background color defined in a Cascaded Style Sheets (CSS) file??
A. ?@bgcolor "color"; B. ?@background="color"; C. ?background: color; D. ?background-color: color;