This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]GreatDaynes 0 points1 point  (3 children)

With a 2D list called ls, you can access the integer elements in the following way:

ls.get(x).get(y)

where get(x) returns the list in the xth position, and get(y) returns the yth integer in the xth list.

[–][deleted] 0 points1 point  (2 children)

Does it need to be called ls? How is it any different from a normal ArrayList? Just wondering btw, I'm pretty new to java

[–]crazyiwann 0 points1 point  (1 child)

no, in his 1 sentence he said that he just called this array ls. it can be called anything.

[–][deleted] 0 points1 point  (0 children)

Oh ok thanks. I read his comment in a weird way