Created
January 24, 2016 10:20
-
-
Save taisyo7333/0b0828a383ca13c1e99e to your computer and use it in GitHub Desktop.
Ruby Exception
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
# encoding: SJIS | |
begin | |
1/0 | |
rescue | |
p 1 | |
rescue ZeroDivisionError # Do not call | |
p 2 | |
end | |
# => 1 |
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
>ruby Code3-164.rb | |
ruby Code3-164.rb | |
1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment