Find A String Hackerrank Solution Python