From 08f706be1d42f58eb5ac196baa61d0bea4c277ee Mon Sep 17 00:00:00 2001 From: Priya Date: Thu, 14 Jan 2016 10:19:22 -0500 Subject: [PATCH] Completed --- parser.rb | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/parser.rb b/parser.rb index adaad3e..125824f 100644 --- a/parser.rb +++ b/parser.rb @@ -1,3 +1,9 @@ def word_in_string?(word, string) - # implement with your code here + + string_store = string.gsub(/[_-]/,' ').split(/\s/) + if string_store.include? word + return :yes.to_sym + else + return :no.to_sym + end end