| 1 | initial version |
You can use the itertools Python module and make the product of enumerate(GF(2^7)) with itself four times as follows:
sage: from itertools import product
sage: for ((i0,a0),(i1,a1),(i2,a2),(i3,a3)) in product(enumerate(GF(2^7)), repeat=4):
....: print ((i0,a0),(i1,a1),(i2,a2),(i3,a3))
Copyright Sage, 2010. Some rights reserved under creative commons license. Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.