2013-07-09 10:46:31
Map is a very useful java container to store data of key/value pairs. In this example you will see how to create and populate a map.
public void MapExample()
{
Map<String,String> map=new HashMap<String, String>();
map.put("key1", "value 1");
map.put("key2", "value 2");
map.put("key3", "value 3");
String s;
s=map.get("key2");
}
;3515;2013-07-09 10:46:31__s__ Map is a very useful java container to store data of key/value pairs. In this example you will see how to create and populate a map.
public void MapExample()
{
Map<String,String> map=new HashMap<String, String>();
map.put("key1", "value 1");
map.put("key2", "value 2");
map.put("key3", "value 3");
String s;
s=map.get("key2");
}
__s__~u=Zac~site=NULL__s__Java Example create and populate Map__s____m__
17,CSS;15,javascript;16,javascript CSS;8,XML C/C++;10,XML converter;12,XML data warehouse;13,XML database;4,XML editor;1,XML general;11,XML HTML;7,XML java;6,XML javascript;5,XML parser;9,XML PHP;2,XML schema;3,XML syntax;14,XPath;