# File link.rb, line 29 def getResponse(input="") p 'INPUT==' + input # check for words that are too long if input =~ /(\w){20,20}/ puts "There is a word that is too long." return "There is a word that is too long." end if input.size > 300 return "The input exceeded maximum length." end if input == "\"\"" return "Sorry I didn't get that..." end begin return puts(input.to_s) rescue => error return "Sorry I get an error when parsing that sentence: " + error end end