Skip to content

Instantly share code, notes, and snippets.

@dtan4
Last active December 13, 2015 23:49
Show Gist options
  • Save dtan4/4994089 to your computer and use it in GitHub Desktop.
Save dtan4/4994089 to your computer and use it in GitHub Desktop.
# char -> int
p "A".ord
#=> 65
# int -> char
p 1.chr()
#=> "\x01"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment