Quite possibly the best way to test this is to write a small little program that confirms your suspicions that it works or fails (in larger application development this is called writing a Test...
Type: Posts; User: copeg
Quite possibly the best way to test this is to write a small little program that confirms your suspicions that it works or fails (in larger application development this is called writing a Test...
Take a look at the Map interface
The Map Interface (The Java™ Tutorials > Collections > Interfaces)
It will allow you to map keys to values. In the example you gave, there are many different ways...