Is there a way to read 10000 lines from a file in python?
<p>I am relatively new in python, was working on C a lot. Since I was seeing so many new functions in python that I do not know, I was wondering if there is a function that can request 10000 lines from a file in python.</p>

<p>Something like this is what I expect if that kind of function exist:</p>

<pre><code>lines = get_10000_lines(file_pointer)
</code></pre>

<p>Did python have a build-in function or is there any module that I can download for this?
If not, how do I do this to be easiest way. I need to analyze a huge file so I want to read 10000 lines and analyze per time to save memory.</p>

<p>Thanks for helping!</p>
