Get stuck!


#1



https://www.codecademy.com/en/courses/ruby-beginner-en-JdNDe/0/6?curriculum_id=5059f8619189a5000201fbcb#


Welcome to hissed world. Type your message here! adfg
undefined method `include?' for nil:NilClass
Oops, try again. Your code doesn't look quite right. Check the first exercise if you need help!


print 'Welcome to hissed world. Type your message here!'
user_input = gets.chomp.downcase!
if user_input.include? 's'
    user_input.gsub!(/s/,'th')
else print 'You are not a hissed person!'
end


#2

Separate your gets.chomp and your downcase!

user_input = gets.chomp
user_input.downcase!

#3

Llike so

print 'Welcome to hissed world. Type your message here!'
user_input = gets.chomp.
user_input.downcase!
if user_input.include? 's'
    user_input.gsub!(/s/,'th')
else print 'You are not a hissed person!'
end

still not working


#4

You gotta remove the period after gets.chomp


#5

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.