Hi all,
I am working through Learn Ruby the Hard way and am a bit unsure as to
how to tackle the following bug. A asked an experienced friend for help
and he suggested using regular expressions. Is there a simpler way to
approach this?
The problem is here:
http://ruby.learncodethehardway.org/book/ex35.html
On line 7/8 the author states there is a bug. I presume the bug is that
it doesn’t capture all types of integer…But without a way to confirm
whether the input is an integer, how can I fix this?
If someone could point me in the right direction I’d really appreciate
it!
Thanks