-4
Merry Christmas to all!
How do I, in java, that array?
{
"Aluno" => "fulano",
"Idade" => 33
}
I thought about Arraylist, but it didn’t work out
I thought about List, also did not work
Think about String[] , same thing
They don’t seem to accept indexes.
Use
Map
: https://docs.oracle.com/javase/tutorial/collections/interfaces/map.html– hkotsubo
Or create a class with the attributes you want.
– Piovezan