Need help with these two challenges

  1. Add an additional if statement to re-prompt the user for input if they don't enter anything.
  2. Think about how you might account for words in which the letter "c" sounds like an "s".

I am stuck with these challenges, please help me!

print "what is your name!"
user_input = gets.chomp

if user_input.include? "s"
user_input.gsub!(/s/, "th")

puts "there is no s in your input!"

puts "your string is, #{user_input}"



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