• Cours
  • Compilateur de code
  • Discuter
  • Tarification
  • Équipes
Menu
0

First line question

I think it’s should be ArrayList<String> list = new<String> ArrayList; Instead List <String> list = new<String> ArrayList;

spelling
1st Jun 2019, 10:21 PM
Ivanov Viktor
Ivanov Viktor - avatar
1 Réponse
+ 2
Here is an explanation: https://stackoverflow.com/questions/9852831/polymorphism-why-use-list-list-new-arraylist-instead-of-arraylist-list-n
2nd Jun 2019, 12:29 AM
Denise Roßberg
Denise Roßberg - avatar

Vous avez souvent des questions comme celle-ci ?

Apprenez de maniĂšre plus efficace, gratuitement :

  • Introduction Ă  Python

    7.1M apprenants

  • Introduction Ă  Java

    4.7M apprenants

  • Introduction Ă  C

    1.5M apprenants

  • Introduction Ă  HTML

    7.5M apprenants

Voir tous les cours
Aujourd'hui en vedette
I have finished first in Saturn League 3 times in a row, why have I not been given the badge for “Intergalactic Champion”
3 Votes
I am new
1 Votes
Changing String Variables into int in C++
0 Votes
Advertising in Sololearn
1 Votes
Python intermediate help with dictionaries
0 Votes
Fill in the blank to declare a static variable.
0 Votes
Marquee
1 Votes
RUST'S FUTURE
1 Votes
Question #2: "Please activate your account and keep learning to enable messaging. An email has been sent to you"
1 Votes
Programming Language
0 Votes