generate functionWed, 30 Nov 2022

find if the given string has the letter "e" in it, and output an alert if so

def has_e(str) if str.include? "e" puts "We have an e." else puts "No e here." end end

Questions about programming?Chat with your personal AI assistant