What are Python implementation of nextInt(), hasNext() from Java?
<p>I have this input file</p>

<pre><code>1 2
10 2
81 3
23 6
2537857295 19
34271891003654321 1267253
</code></pre>

<p>I am reading the file like this</p>

<pre><code>with open("powersearch.txt") as fileIn:
    for line in fileIn:
        print line
</code></pre>

<p>I am wondering if I want to, for every single line, have the 1st integer stored as <code>firstNum</code>, the 2nd stored as <code>secondNum</code>. With Java I can use a <code>scanner</code> and do <code>nextInt()</code> and <code>hasNext()</code> to get the integers, what are the equivalent in Python?</p>
