1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
evablogger [386]
3 years ago
6

Consider the following statement, which is intended to create an ArrayList named years that can be used to store elements both o

f type Integer and of type String. /* missing code */ = new ArrayList(); Which of the following can be used to replace /* missing code */ so that the statement compiles without error?
a. ArrayList years
b. ArrayList years()
c. ArrayList years[]
d. ArrayList years
e. ArrayList years
Computers and Technology
1 answer:
zvonat [6]3 years ago
7 0

Answer:

a. ArrayList years

Explanation:

Required

Complete the code segment

The programming question is about Java programming language.

In java, the syntax to declare an ArrayList of no specific datatype is:

ArrayList [List-name] = new ArrayList();

From the question, the name of the ArrayList is years.

So, the syntax when implemented is:

<em>ArrayList years = new ArrayList();</em>

<em>So, the comment /*missing code*/ should be replaced with: ArrayList years</em>

You might be interested in
A ________ database state is one in which all data integrity constraints are satisfied
beks73 [17]
A consistent database base is one in which all data integrity constraints are satisfied.
8 0
3 years ago
Read 2 more answers
Which source would provide the best way to find valid information about climate change
igor_vitrenko [27]
Primary sources would be best
4 0
3 years ago
A wireless network does not benefit like a wired network does, when it comes to collision reduction. Which device reduces collis
Leviafan [203]

Answer:

Switch

Explanation:

The network switch is an networking hardware also known as a network bridging device used to connect devices on the network together and receives and forward data from source to destination through packet switching.

In order to eliminate or reduce collision within the network, present day wired networks make use of network switches that connects each device to its own port on the switch, making the switch the domain of collision for half duplex links or whereby the link is a full duplex links the collision possibility is completely eliminated.

3 0
3 years ago
USDA-APHIS Animal Care Resource Policy #12 "Considerations of Alternatives to Painful/Distressful Procedures" states that when a
katrin2010 [14]

Answer:

C. The specific field of study

C. change in anesthetic agent

Explanation:

In the consideration for the procedure, some information are required and examples are the strategy of the search/the database name. However, the area of study is not one of the information.

The animal use proposal can general be altered based on the type of change required. However, an anesthetic agent alteration is not a significant change.

6 0
3 years ago
If the ____________ is broken on a laptop, chances are other parts are also broken.
ella [17]
Central processing Unit
8 0
3 years ago
Other questions:
  • 7 features of QBASIC
    6·1 answer
  • How do you spell kiss in Japanese
    13·2 answers
  • Which device lets you hear audio on your computer?
    12·2 answers
  • The_provides access to the internet may also be internal​
    9·1 answer
  • What is a printed copy of computer output called
    10·2 answers
  • What is the name of the program file that you can enter in the Windows search or Run box to execute Event Viewer? What process i
    12·1 answer
  • How will using ascending order on a field that contains dates sort a list?
    12·2 answers
  • Int a=10 int b=20<br> A=b<br> The new values for a and b are
    11·2 answers
  • 2:3:5<br>_ _ _<br>3 2 8<br><br><br><br>find ratio​
    5·1 answer
  • ¿Es lo mismo hablar de tecnología que de computadora?
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!