Text identification
<p>Let's say I have a list of some strings (movie names in my case) and now I have a new sentence which contains one of the string from the list of strings. How do I find that which string does the sentence has? 
For eg:</p>

<pre><code>list_of_strings = ['20th century women', 'green is gold ', 'fire at sea']
sentence = 'Official Trailer | Green is  gold - Releasing Tomorrow'
</code></pre>

<p>For above case, solution should be able to find that <em>sentence</em> contains <em>green is gold</em>.
Please suggest which algorithm are available to solve this issue. Implementation/Library in Python will also work. </p>

<blockquote>
  <p>Sentences might contain little different spellings.</p>
</blockquote>

<p>List of strings has 10000-15000 strings.</p>

<p>Its a slight modification of standard problem of finding occurrences of set of words in a given input text. This problem can be efficiently solved by <a href="https://en.wikipedia.org/wiki/Aho%E2%80%93Corasick_algorithm" rel="nofollow">Aho-Corasick</a> Algorithm. You can modify the source codes available for the algorithm to match you needs.<br>
Though sub-string functions can help you as answered by others but they work on small inputs. For larger input strings you will needed some linear time algorithm.</p>

python algorithm text