Shortest expression for {0, 3, 2, 5, 0, 3, 5, 1, 4, 6, 2, 4}
2 2.2
I love arbitrary precision arithmetic.
0x4126030156610&gt;&gt;(n&lt;&lt;2)

Or, if you don't like hex,
1146104239711760&gt;&gt;(n&lt;&lt;2)

Test:
print([(0x4126030156610&gt;&gt;(n&lt;&lt;2))%7 for n in range(1,13)])
[0, 3, 2, 5, 0, 3, 5, 1, 4, 6, 2, 4]