<p>As noted, it's really only counterintuitive if your intuition is primed to expect C style right to left chained assignments.</p>
<p>Python, on the other hand, is able to preserve primarily left to right evaluation in this case with only the far right hand expression needing to be evaluated out of order.</p>
<p>One example that can really make the intended behaviour clear:</p>
<p>*a = *b = iter(range(3))</p>
<p>a ends up as (0,1,2), b ends up as (), because the first assignment consumes the entire iterable.</p>
<p>My actual advice, though? If the order of assignment really matters, use multiple assignment statements rather than relying on readers knowing the assignment order.</p>
<p>Cheers,<br>
Nick.</p>
<p>--<br>
Sent from my phone, thus the relative brevity :) </p>