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
neonofarm [45]
3 years ago
8

Which of the following does not correctly declare an ArrayList?

Computers and Technology
1 answer:
kotegsom [21]3 years ago
6 0

Answer:

Option b. ArrayList‹Integer› = new ArrayList‹Integer›(10) does not correctly declare an ArrayList.

<u>Explanation</u>:

ArrayList in Java dynamically stores elements in it. It also called as re- sizeable array as it expands  in size when elements are added and decreases when an element is removed from it. This array list class also allows to use duplicate and null values.

The syntax for creating Array list is as follows

ArrayList<Type> obj = new ArrayList<Type>()

Type  specifies the type of ArrayList like Integer, Character, Boolean etc, and obj is the object name. But in the option b ArrayList‹Integer› = new ArrayList‹Integer›(10)  object name is missed and not specified.

You might be interested in
10. Differentiate between equity share &amp; preference share.​
IrinaVladis [17]

Answer:

Equity Shares are commonly called Common shares and have both advantages and disadvantages over Preference shares.

  • Equity shareholders are allowed to vote on company issues while preference shareholders can not.
  • Preference shareholders get paid first between the two in the case that the company liquidates from bankruptcy.
  • Preference shareholders get a fixed dividend that has to be paid before equity share dividends are paid.
  • Preference shareholders can convert their shares to Equity shares but equity shareholders do not have the same courtesy.
  • Preference shares can only be sold back to the company while equity shares can be sold to anybody.

5 0
3 years ago
What is output by the following line of code?
astraxan [27]

Answer:int x = 5;

if(x < 5)

cout << "line 1 ";

cout << "line 2";

A. line 1 line 2 B. line 1 C. line 2

D. line 1 E. line 1line 2

line 2

2. What would be output by the following code? _______

int x = 0;

while(x < 5)

{

cout << x << " ";

x++;

}

A. 0 1 2 3 4 5 B. 1 2 3 4 5 C. 0 1 2 3 4

D. 0 E. 0 0 0 0 0

3. After execution of the following code, what will be the value of input_value if the value 3 is entered at the keyboard at run time? ________

cin >> input_value;

if (input_value > 5)

input_value = input_value + 5;

else if (input_value > 2)

input_value = input_value + 10;

else

input_value = input_value + 15;

a. A. 8

b. B. 13

c. C. 18

d. D. 0

e. E. 5

4. What would the user see displayed on the screen after the following lines of code are executed?¬¬________

int i = 6;

if (i == 10)

cout << “value: “ << i;

else

cout << "hmmm";

A. value: i B. value: 10

C. hmmm D. value: ihmmm

E. value: 10

Hmmm

5. What is the output of the following lines of code? ______

for(int i=0; i<4; i++)

cout << (i * 3) << " ";

A. 0 1 2 3 4 B. 0 3 6 9

C. 0 3 6 9 12 D. 0 1 2 3 E. 0 0 0 0

Explanation:

6 0
2 years ago
Overlay analysis is ____________, taking in data from two or more layers to create a single output layer.
Wewaii [24]

Explanation:

Overlay analysis is an approach, taking in data from two or more layers to create a single output layer.

For example, if we have a layer of land use and a layer of soil fertility, we can derive from the two layers the percentage of agricultural land developed over fertile soil.

6 0
3 years ago
How does abstraction make programming languages easier to use
alexgriva [62]

Abstraction make programming languages easier to use as  It eliminates the need for codes to be automated.

<h3>How does abstraction make programming languages easier to implement?</h3>

Data abstraction is known to be a tool that helps a person to change a complex data structure into simple ones which can be used easily.

Note that Abstraction make programming languages easier to use as  It eliminates the need for codes to be automated.

Learn more about abstraction from

brainly.com/question/7994244

#SPJ1

6 0
2 years ago
An additional factor in how an element is rendered is that properties are passed from a parent element to its children in a proc
belka [17]

Answer:

style inheritance

Explanation:

What happens when a property on an element has no value supplied is governed by style inheritance. A property should inherit its value from its parent element, according to this specification.

6 0
2 years ago
Other questions:
  • In dt.py, you will implement a basic decision tree classifier for
    5·1 answer
  • You should use _____ software for writing a letter.
    10·1 answer
  • ________ is used to store programs and instructions that are automatically loaded when the computer is turned on.
    14·1 answer
  • You are to create a program using Python that asks the user for a nonnegative number, then computes the mean and variance using
    15·1 answer
  • In an inheritance situation, the new class that you create from an existing class is known as the:
    5·1 answer
  • A bitmap picture can be represented by hexadecimal numbers. Each two-digit hexadecimal number represents a row. To convert a num
    14·1 answer
  • Working at a ski resort in the mountains has its own unique security issues. Kenny is the chief information officer for Sundance
    10·1 answer
  • To close the ____ view, click File on the Ribbon or click the preview of the document in the Info gallery to return to the docum
    9·1 answer
  • What is online school like 6 sentences
    12·1 answer
  • Suppose that we are using PDDL to describe facts and actions in a certain world called JUNGLE. In the JUNGLE world there are 4 p
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!