From 18739e3dad6cfb042f3b5328b9e529cddc1edf27 Mon Sep 17 00:00:00 2001 From: Rajashree K Maiya Date: Tue, 12 Jan 2016 13:18:50 -0500 Subject: [PATCH] rmaiya_solution-Parser1 --- parser.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/parser.rb b/parser.rb index adaad3e..5cce906 100644 --- a/parser.rb +++ b/parser.rb @@ -1,3 +1,4 @@ def word_in_string?(word, string) - # implement with your code here + string = string.gsub(/_|-/," ") + /^(.*(\b#{word}\b).*)$/.match("#{string}")? :yes : :no end