Is there a way to write this nicer?
<p>I need to write these four IFs in Python. Notice what it does is changing between 4 possible states in a loop 1,0 -> 0,1 -> -1,0 -> 0,-1 -> back to first.</p>

<pre><code>if [dx, dy] == [1,0]:
    dx, dy = 0, 1
if [dx, dy] == 0, 1:
    dx, dy = -1, 0
if [dx, dy] == [-1, 0]
    dx, dy = 0, -1
if [dx, dy] == [0, -1]:
    dx, dy = 1, 0
</code></pre>

<p>Can anyone suggest me a better/nicer way to write this?</p>

<p>Thanks.</p>
