How to make this python script faster?
<p>I tried to find an overlap list from two set of list.
I first generate first list by </p>

<pre><code>while True:
    line=f.readline()
    if not line:
        break
    list_1.append(line)
</code></pre>

<p>and use this list to scanning through the second file:</p>

<pre><code>while True:
    line1=f1.readline()
    if not line1:
        break
    for i in list_1:
        if i==line1[:17]:
            list_2.append(line1)
</code></pre>
