Created
August 7, 2015 21:13
-
-
Save kenmazaika/099067a6f5b577038434 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| def reverse_str(str) | |
| letters = str.chars | |
| reversed = [] | |
| while letters.length > 0 | |
| reversed << letters.pop | |
| end | |
| return reversed.join | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment