Ruby - Regular Expressions
What will be the output of this Ruby code?
sentence = "Welcome to Ruby" position = sentence =~ /Ruby/ puts position
sentence = "Welcome to Ruby" position = sentence =~ /Ruby/ puts position
15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions