brennadrummond5042 brennadrummond5042
  • 25-07-2019
  • Computers and Technology
contestada

If the list above is named list1 and is implemented as a list, whatstatement would you use to find the number ofelements?list1.size()list1.numElementslist1.lengthlist1.contains

Respuesta :

Branta Branta
  • 01-08-2019

Answer:

list1.size()

Explanation:

In order to find the number of elements in a List , we can use the size() method defined in the java.util.List interface.

This method returns an integer which corresponds to the number of elements in the list.

The usage syntax example is as follows:

int num = list1.size();

If the list referenced by list1 contains 6 elements, then this method will return the value 6.

Answer Link

Otras preguntas

Which wave has a disturbance that is perpendicular to the wave motion?
Enter the number 10.333333333333 rounded to the nearest hundredth (two decimal places):
In narrative nonfiction, the details ____. Question 4 options: make the reader think they are reading fiction make the reader want to read more stories paint a
Pleaseeeeee i need this
Write a two column proof of the statement. If 9k - 5 = 7k + 3, then k = 4.
1. Listen to the audio and select the correct answer: At what time is the math class? (2 points) 10:30 a.m. 10:15 a.m. 2:30 p.m. 2:15 p.m.
Divide. Give the quotient and remainder. 5429 divide by 3
18,472 divided by 376 and no links
Distance between the lines 3x +4y =9 and 6x + 8y =15 is
Hi! Does anyone know the answer to this question? Will mark brainliest! What is shown in this illustration? A. continental-continental convergence boundary B.