Skip to content

Instantly share code, notes, and snippets.

@abrongersma
Created September 16, 2012 06:25
Show Gist options
  • Save abrongersma/3731283 to your computer and use it in GitHub Desktop.
Save abrongersma/3731283 to your computer and use it in GitHub Desktop.
def smiley(hash)
myhash = {"happy" => ":)"}
hash.each do |key, value|
end
myhash["happy"]
end
@abrongersma
Copy link
Author

hash = {"mood" => "happy"}
hash["mood"]
== "happy"

@abrongersma
Copy link
Author

Hash[ [ ["a", 100], ["b", 200] ] ]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment