pythonとprogに関するakhiのブックマーク (6)

  • 手作り有限状態機械で字句解析

    a.py #!/usr/bin/env python class Parser(object): def __init__(self): self.parse1 = self.parse_main self.items = [] self.item = '' return def feed(self, text): i = 0 while i < len(text): (self.parse1, i) = self.parse1(text, i) return def parse_main(self, text, i): c = text[i] if c == ',': self.finish_item() return (self.parse_main, i+1) elif c == '"': return (self.parse_quote, i+1) elif c == '\\':

  • FrontPage - Numerical Analysis with Python

    このサイトについて † SciPyを中心としたPythonによる数値解析モジュールとそれに関連する話題のwikiです。 間違い等、気付いたことがあれば適宜加筆・修正していただけるとうれしいです。 (今のところ誰でも自由に編集できるようになっています) ↑ Pythonって何? † www.python.orgより Python is an interpreted, interactive, object-oriented programming language. It is often compared to Tcl, Perl, Scheme or Java. Python combines remarkable power with very clear syntax. It has modules, classes, exceptions, very high level

  • ホーム — PythonMatrixJp

    wheezy.webいいかもー(1) wheezy.webという新しいフルスタック軽量WebFrameworkがリリースされています。 モダンな作りでかつ役割分担を明確に分離してデザインされています。 コードがシンプルで、アプリの実装に対して 極力オーバーヘッドにならないよう注意深く実装されています。 「契約によるデザイン」やベンチマークテストも取り入れていて 多人数での開発でも耐えうる仕掛けを持っているようです。 サイト: https://bitbucket.org/akorn/wheezy.web ドキュメント: http://packages.python.org/wheezy.web/ 続きを読む...

  • http://trichech.us/?page_id=5

  • PythonSpeed

    PythonSpeed 多くの人がPythonプログラムの速度について心配を持っています。でもPythonを使わないと、堪らないくらい実行速度上のロスがありますよね? 中には「なんだ、インタプリタのスクリプト言語か、まるっきり遅いや」なんて結論づける人もいます。また、Pythonを実際に試してみて、実行効率が十分なことに気づく人もいます。でも時には、 とっても遅いプログラムができあがることもあります。 実行速度がそんなに重要?ホントに? 多くの人が必要以上に速度に取りつかれていて、このような種類の問題では、Cが優れた実績を示していることから、全ての面で優れた言語だと考えています。別の人々は、開発の速度がより重要で、Pythonを選ぶのはそのような時に限り、まあそれなりの速度だろうと考えています。そして頻繁に、期待を超えた速度で動いていることに驚かされています。時には、同じ開発時間を費やした

  • Python 2.4 クイックリファレンス

    Does the web look weird? Ugly? Perhaps that's because your browser does not support the CSS standard. I recommend you consider updating it. Without CSS, this and other pages are visible, but nothing like they were meant to be. A very good free browser with support for all standards is Firefox. For information about standards and why they are important, please visit the browser upgrade campaign. St

  • 1