I'm trying to check whether input from user matches RegEx [a-zA-z]
so I've checked the docs for proper method. I found match?
in Ruby-doc.org and copied the example shown in docs to irb, but instead of true
I'm getting this:
2.3.3 :001 > "Ruby".match?(/R.../)
NoMethodError: undefined method `match?' for "Ruby":String
Did you mean? match
from (irb):1
from /usr/local/rvm/rubies/ruby-2.3.3/bin/irb:11:in `<main>'
Why this method doesn't work in my irb?