String and int together in arrays—how? | Sololearn: Learn to code for FREE!


String and int together in arrays—how?

I have an assignment that needs to display the sample COVID cases in Philippines, Indonesia and China, with their central cities on Manila, Jakarta and Beijing respectively. On top of that, those countries have 2000, 5000 and 10000 cases respectively (sample cases). I need to use the multidimensional array, but I'm nowhere from being able to run one without fail. How can I put strings and int together in arrays?

12/15/2020 2:38:13 AM

Julie Mae Javier

6 Answers

New Answer


Can you use a hashmap instead?


Julie Mae Javier In which language are you trying to do that?


You can use dictionaries in python


Krish , Java. I'm using Java


Sonic , hashmap? How?


Swaya , hello. But I am using Java as per learning competency given by the Department of Education (here in my country)