Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- User = Struct.new(:password, :additional_info)
- hash=Hash.new {|h,k| h[k] = User.new}
- list_of_user-password-pairs.each do |user, password|
- hash[user].password = password
- if user=="sepp2k"
- hash[user].additional_info = "The greatest person in the world."
- end
- end
Add Comment
Please, Sign In to add comment