Skip to main content

Home/ Python/ Group items tagged programming

Rss Feed Group items tagged

reckoner reckoner

Huffman coding in Python - Program - Python - Builder AU - 0 views

  • In our last article on compression we showed you how to demonstrate run time encoding in Python. In this article we'll show you how to implement another kind of compression, Huffman encoding, which is useful when dealing with small sets of items, such as character strings.
reckoner reckoner

Python Idioms and Efficiency Suggestions - 0 views

  • What idioms should I use to make my code easier to read? Read "The Python Cookbook", especially the first few chapters. It's a great source of well-written Python code examples.
  • Use function factories to create utility functions. Often, especially if you're using map and filter a lot, you need utility functions that convert other functions or methods to taking a single parameter. In particular, you often want to bind some data to the function once, and then apply it repeatedly to different objects. In the above example, we needed a function that multiplied a particular field of an object by 3, but what we really want is a factory that's able to return for any field name and amount a multiplier function in that family:
  • Use zip and dict to map fields to names. zip turns a pair of sequences into a list of tuples containing the first, second, etc. values from each sequence. For example, zip('abc', [1,2,3]) == [('a',1),('b',2),('c',3)]. You can use this to save a lot of typing when you have fields in a known order that you want to map to names:
  •  
    suggestions for better programming style.
reckoner reckoner

Chapter 14. Test-First Programming - 0 views

  •  
    good introduction to unit-testing
reckoner reckoner

Charming Python: Inside Python's implementations - 0 views

  • To attempt to explain it in the simplest terms, a continuation is a representation, at a particular point in a program, of everything the program is capable of doing subsequently. A continuation is a potential that depends on initial conditions. Rather than loop in a traditional way, it is possible to invoke the same continuation recursively with different initial conditions. One broad claim I have read is that continuations, in a theoretical sense, are more fundamental and underlie every other control structure. Don't worry if these ideas cause your brain to melt; that is a normal reaction.
Raúl - [^BgTA^]

Zato | home page - 0 views

  •  
    The next generation ESB and application server written in Python and released under a commercial-friendly LGPL license.
Raúl - [^BgTA^]

Brython - 1 views

  •  
    Free implementation of Python for web client development
reckoner reckoner

Bruce Eckel's MindView, Inc: Thinking in Python - 0 views

  •  
    draft version is downloadable
reckoner reckoner

Testoob - Python Testing Out Of The Box - About - 0 views

  • Testoob is an advanced unit testing framework for Python. It integrates effortlessly with existing PyUnit (module ‘unittest’) test suites.
reckoner reckoner

Pygments - Python syntax highlighter - 0 views

  • This is the home of Pygments. It is a generic syntax highlighter for general use in all kinds of software such as forum systems, wikis or other applications that need to prettify source code. Highlights are:
reckoner reckoner

Statistical Computing With Python - 0 views

  • StatPy: Statistical Computing with Python Welcome to StatPy, a collection of resources to help you do statistical computing with Python, with a special emphasis on astrostatistics (statistics in astronomy). This web site is brand-spanking-new, and still very much under construction; please be patient with our "dust" and check back again frequently as building continues.
reckoner reckoner

Python and HTML Processing - 0 views

  • Various Web surfing tasks that I regularly perform could be made much easier, and less tedious, if I could only use Python to fetch the HTML pages and to process them, yielding the information I really need. In this document I attempt to describe HTML processing in Python using readily available tools and libraries.
  •  
    Various Web surfing tasks that I regularly perform could be made much easier, and less tedious, if I could only use Python to fetch the HTML pages and to process them, yielding the information I really need. In this document I attempt to describe HTML pro
reckoner reckoner

Python: Lambda Functions - 1 views

  •  
    lambda functions
reckoner reckoner

Charming Python: Using state machines - 2 views

  • Charming Python: Using state machinesAlgorithms and programming approaches in Python
reckoner reckoner

ONLamp.com -- Introduction to Stackless Python - 0 views

  • Stackless Python is an alternative implementation of Python created by independent developer Christian Tismer. He started with the conventional Python language processor managed by the language's inventor, Guido van Rossum, and patched his own Stackless invention in place of a small but central part of Python's internals. Stackless Python is the result. This article introduces Tismer's technology and its significance. In future articles, you'll be able to read about how to make your own start at programming Stackless Python, as well as the prospects for a merger between Stackless and the main Python distribution.
1 - 20 of 27 Next ›
Showing 20 items per page