pythonのリンク集
Under Construction
- 英語のページ
- 日本語のページ
- Pythonのライバル
- 未分類
- http://www.dstc.edu.au/Fnorb/
- ftp://ftp.parc.xerox.com/pub/ilu/ilu.html
こういうコードは書いてはいけないという反例
-
- get fibonacchi series (by Ulf Bartelt)
- map((lambda x,f=lambda x,f:(x<=1) or (f(x-1,f)+f(x-2,f)): f(x,f)),xrange(20))
-
- instead of range function (how can I write letrec?)
- (lambda x,f=lambda x,f:x and f(x-1,f)+[x] or []: f(x,f))(10)
-
- incorporation of above two
- map((lambda x,f=lambda x,f:(x<=1) or (f(x-1,f)+f(x-2,f)): f(x,f)),(lambda x,f=lambda x,f:x and f(x-1,f)+[x] or []: f(x,f))(20))
-
- prime sequence (by Ulf Bartelt)
- filter(None,map(lambda y:y*reduce(lambda x,y:x*y!=0,map(lambda x,y=y:y%x,range(2,int(pow(y,0.5)+1))),1),range(2,1000)))
-
- another version of prime sequence (sieve)
- (lambda x:(lambda x,h=lambda x,h:x and x[0:1]+h(filter(lambda y,a=x[0]:y%a,x[1:]),h):h(x,h))(range(2,x)))(1000)
-
- stupid lambda nest example
- (lambda z: (lambda x:map(lambda y,x=x:y*x,[1,2,3]))(z))(3)
-
- stupid len
- reduce(lambda x,y:y+1,range(1000),0)
Last modified: Thu May 25 15:19:16 JST 2000