Last active
August 29, 2015 14:15
-
-
Save gustiando/b9f1a16c32cad0ffbb5d to your computer and use it in GitHub Desktop.
My nasty Ruby REPL
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
| #!/usr/bin/env ruby | |
| def repl | |
| input = gets.chomp | |
| result = eval input | |
| puts result | |
| repl | |
| end | |
| repl |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment