+ 1

What is the output of this code?

ArrayList<String> list = new ArrayList<String>(); list.add("A"); list.add("B"); list.add("C"); System.out.println(list.get(0));

28th Jul 2020, 4:43 AM
HALAI JAYESHKUMAR
HALAI JAYESHKUMAR - avatar
18 ответов
+ 6
B
8th Aug 2021, 12:30 PM
W.G.A.C.Nandasena
W.G.A.C.Nandasena - avatar
+ 4
A
28th Jul 2020, 11:54 AM
HALAI JAYESHKUMAR
HALAI JAYESHKUMAR - avatar
+ 2
You can run the code and see for yourself.
28th Jul 2020, 5:14 AM
XXX
XXX - avatar
+ 2
a
9th Aug 2021, 4:37 AM
NEFI JOSE MORALES TAJTAJ
NEFI JOSE MORALES TAJTAJ - avatar
+ 2
B
1st Jan 2022, 11:45 AM
M.I.M.Aqueel
M.I.M.Aqueel - avatar
+ 1
a
1st Jan 2022, 12:22 PM
M.I.M.Aqueel
M.I.M.Aqueel - avatar
+ 1
answer is A
8th Jan 2022, 10:57 AM
D.SUJIVAN
+ 1
B
8th Jan 2022, 4:53 PM
J.A.D.S. Tharuka
+ 1
B
9th Apr 2022, 3:20 AM
Ronald Gorgonia
+ 1
B
9th May 2022, 4:24 PM
U.L.F. Feroza
+ 1
B
3rd Jul 2022, 8:23 AM
Janidu Wathsara
+ 1
B
10th Apr 2023, 11:25 AM
Eden Mekonnen
Eden Mekonnen - avatar
0
Maybe Answer is 0
28th Jul 2020, 7:38 AM
Lalkar Zirange
Lalkar Zirange - avatar
0
a
23rd Nov 2021, 9:12 AM
Nabila Muftia Ma'ruf Kartono
Nabila Muftia Ma'ruf Kartono - avatar
0
Correct ans is B not A
18th Jul 2022, 1:59 PM
Avani Somayaji
Avani Somayaji - avatar
0
B is correct
22nd May 2023, 5:26 AM
Divya Karnati
0
B Because index starts from 0 and asked is 1
29th Jun 2023, 11:34 AM
Boggarapu Sai raghav
Boggarapu Sai raghav - avatar
- 2
No
28th Jul 2020, 11:54 AM
HALAI JAYESHKUMAR
HALAI JAYESHKUMAR - avatar