Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

use hashtables instead of strings  RSS feed

 
nicky sajdok
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
The code below prints this out
[goods out, firstname, lastname]
[id, adress1]
[country, phone]
[goods in]
Now how can i get my code to print out the same, but instead of using the strings Values and keys,
use hashtables?
Also how can i do it without using the (public static void getval)
Hope You can solve this
nicky
 
Layne Lund
Ranch Hand
Posts: 3061
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you looked at the Java API docs? It explains the methods for the Hashtable class very thoroughly. You should be able to at least get a start on it from there. Please come back with some specific questions if you run into any trouble along the way.
Layne
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!