Ask coding questions

← Back to all posts
confused?
coebus (0)

This is my code:

def function_we_built_for_you(str)

str = "#{str}!"
str = str.upcase!
return str
end

(function_we_built_for_you("hello world"))

=> HELLO WORLD!


When I use the same code for my challenge example in Repl, it says the code failed. I am supposed to return a string without using puts. As you can see it works here. Please advise. Thanks!

Commentshotnewtop
Geocube101 (379)

If you can't print with puts try p

p "Hello"