Tag: development
-
Web.py on MacOSX
I’m loving web.py for developing tiny web apps. Here’s how to get it going on a Mac: sudo port -v install python2.4 py-setuptools mysql5 #coz macports insists on adding a ‘5’ suffix to all mysql5 tools. sudo ln -s /opt/local/bin/mysql_config5 /opt/local/bin/mysql_config sudo easy_install web.py cheetah markdown MySQL-python DBUtils Not the twenty odd steps that’s on […]
-
Tail Recursion
Ponder this: fact (0) -> 1; fact (N) -> N * fact (N – 1). versus this: fact(N) -> fact_helper(N, 1). fact_helper(1, T) -> T; fact_helper(N, T) -> fact_helper(N – 1, T * N). The advantage of learning Erlang (albeit very slowly, with lots of interruptions) is that it directly introduces a lot of concepts […]