Created
November 25, 2015 23:42
-
-
Save cawel/678a84f5387bb25353c6 to your computer and use it in GitHub Desktop.
blog-quiz-easy-4
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
irb(main):001:0> 3.to_i | |
=> 3 | |
irb(main):002:0> Integer(4) | |
=> 4 | |
irb(main):003:0> "not_an_int".to_i | |
=> 0 | |
irb(main):004:0> Integer("not_an_int") | |
ArgumentError: invalid value for Integer: "not_an_int" | |
from (irb):4:in `Integer' | |
from (irb):4 | |
from :0 | |
irb(main):005:0> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment