Python 3 Print Update on multiple lines
<p>Is it possible to print and update more than one line?
This works for one line:</p>

<pre><code>print ("Orders: " + str(OrderCount) + " Operations: " + str(OperationCount), end="\r")
</code></pre>

<p>and get this: (Of course the numbers update because its in a loop)</p>

<pre><code>Orders: 25 Operations: 300
</code></pre>

<p>I have tried this:</p>

<pre><code>print ("Orders: " + str(OrderCount) + "\rOperations: " + str(OperationCount), end="\r\r")
</code></pre>

<p>and get this: (The number does update correctly)</p>

<pre><code>Operations: 300
</code></pre>

<p>Looking for two lines that are updated like:</p>

<pre><code>Orders: 25
Operations: 300
</code></pre>

<p>and not:</p>

<pre><code>Orders: 23
Operations: 298

Orders: 24
Operations: 299

Orders: 25
Operations: 300
</code></pre>

<p>You probably want <code>\n</code> instead of <code>\r</code>. <code>\r</code> is "carriage return", a.k.a. "go back to the beginning of the line" -- so you're print "Operations" over "Orders".</p>

python