On Mon, 18 May 2009 at 01:13AM -0700, Kwankyu wrote: > In Magma, there is a handy construct like > > [GF(2) | 1,0,1,1] > > to get the list with elements in GF(2). Is there a similar one in Sage > or Python?
Use list comprehensions: [GF(2)(x) for x in [1, 0, 1, 1]] They're very flexible: [GF(2)(x^2) for x in prime_range(5, 25) if Mod(x, 3) == 2] The result of that isn't very interesting, but it shows you what you can do. Dan -- --- Dan Drake <dr...@kaist.edu> ----- KAIST Department of Mathematical Sciences ------- http://mathsci.kaist.ac.kr/~drake
signature.asc
Description: Digital signature