6 kyu

Breaking search bad

1,197 of 2,239dpellier

Description:

The function must return the sequence of titles that match the string passed as an argument.

TITLES is a preloaded sequence of strings.

TITLES = ['Rocky 1', 'Rocky 2', 'My Little Poney']
search('ock') --> ['Rocky 1', 'Rocky 2']
titles = ['Rocky 1', 'Rocky 2', 'My Little Poney']
search(titles, 'ock') --> ['Rocky 1', 'Rocky 2']

But the function return some weird result and skip some of the matching results.

Does the function have special movie taste?

Let's figure out !

Regular Expressions
Debugging

Similar Kata:

More By Author:

Check out these other kata created by dpellier

Stats:

CreatedJan 8, 2014
PublishedJan 8, 2014
Warriors Trained3748
Total Skips108
Total Code Submissions6219
Total Times Completed2239
JavaScript Completions1197
Python Completions1056
Total Stars32
% of votes with a positive feedback rating86% of 412
Total "Very Satisfied" Votes317
Total "Somewhat Satisfied" Votes76
Total "Not Satisfied" Votes19
Total Rank Assessments14
Average Assessed Rank
5 kyu
Highest Assessed Rank
4 kyu
Lowest Assessed Rank
7 kyu
Ad
Contributors
  • dpellier Avatar
  • FArekkusu Avatar
  • albertogcmr Avatar
Ad