Hey I'm getting a weird error when I run this code.
puts "Text to search through: "
text = gets.chomp
puts "Word to redact: "
redact = gets.chomp
words = text.split(" ")
words.each do |word|
if word != redact
print word + " "
print "REDACTED "
I"m on a site trying to do a ruby tutorial and i'm getting a really weird error message from the online interrupter.
It says "Oops, try again. It looks like you didn't print each word from the user's text to the console."
Based on my code does anyone have any clues to what I could be doing wrong?