Last active
April 8, 2018 02:14
-
-
Save joeyAghion/5049d99d9722108f16382d6ffa8edac9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
> "Báe".length | |
=> 4 | |
> "Báe".encoding | |
=> #<Encoding:UTF-8> | |
> "Báe".encode('utf-8', 'utf-8-mac').encoding | |
=> #<Encoding:UTF-8> | |
> "Báe".encode('utf-8', 'utf-8-mac').length | |
=> 3 | |
> "Báe".codepoints | |
=> [66, 97, 769, 101] | |
> "Báe".encode('utf-8', 'utf-8-mac').codepoints | |
=> [66, 225, 101] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment