Services
Find Stuff
Pages
Buy My Apps
Other Stuff I’ve Built
Book Club
Archives
- May 2018
- February 2014
- December 2013
- November 2013
- August 2012
- July 2012
- April 2012
- March 2012
- December 2011
- November 2011
- October 2011
- September 2011
- August 2011
- July 2011
- June 2011
- May 2011
- April 2011
- March 2011
- February 2011
- January 2011
- December 2010
- November 2010
- October 2010
- September 2010
- August 2010
- July 2010
- June 2010
- May 2010
- April 2010
- March 2010
- February 2010
- January 2010
- December 2009
- November 2009
- October 2009
- September 2009
- August 2009
- July 2009
- June 2009
- May 2009
- April 2009
- March 2009
- February 2009
- January 2009
- December 2008
- November 2008
- October 2008
- September 2008
- August 2008
- July 2008
- June 2008
Categories
- Boxing (23)
- Energy (5)
- iPhone (142)
- Jack Handy (283)
- NaNoWriMo (3)
- People (11)
- Planet Microsoft (5)
- Projects (88)
- Python (43)
- Reelviews (13)
- Reverse Engineering (18)
- Six Word Stories (111)
- The Hard Way (3)
- Uncategorized (6)
- UNIX (8)
- Vacation Slides (30)
- Web stuff (51)
Blogroll
Category Archives: Python
Projections
Today I’d like to present a little Python script that extrapolates Webalizer reports. Webalizer is a “fast, free web server log file analysis program” that my webhost uses to produce HTML traffic reports. These reports include month-by-month totals for the … Continue reading
OAuth
I’ve been working with Twitter’s OAuth interface. It’s pretty simple once you get the hang of it, but I found it a little fiddly at the outset. (If you get something subtly wrong It Just Doesn’t Work, and there’s no … Continue reading
Posted in Python
Comments Off
Full Text Search (Part 1)
I want to add full text search (FTS) to my iKnowPeople app. (Have I mentioned that you can buy it on iTunes?). FTS is a pretty old idea, and most DBs support it (albeit usually through some sort of add-on). … Continue reading
I Habd A Code
I’m a bit under the weather, so all I’ve got today is a quick set of useful co-ordinates. They are: (47, 159).
Merry Christmas
s = ‘s = %s; print s %% repr(s)’; print s % repr(s) (Put it in a file, e.g. ps.py, then run python ps.py | python | python | python | python | python | python | python | python … Continue reading
Posted in Python
Comments Off
Probability
Something a little lighter today: a probability puzzle. Consider this snippet of code: def roll(a,b): # Assume that a and b are both integers greater than 0 return random.randint(0,a-1) > random.randint(0,b-1) What is the probability that roll() returns True for … Continue reading
Posted in Python
Comments Off
Time Sink
Do you like Python? Do you enjoy challenges? Well, why not try the Python Challenge? And, just because I think it’s funny, from a 1969 Ebert review: It is said that Orson Welles saw John Ford’s “Stagecoach” 200 times before … Continue reading
Posted in Jack Handy, Python
Comments Off
Licenses
Last week, a reader wrote in with this question: [Y]ou’ve got all this great code, but you haven’t declared a license. Is it public domain, or BSD? This is, as they say, a fair question. I address it today.
Posted in iPhone, Planet Microsoft, Projects, Python, Reverse Engineering, UNIX, Web stuff
Comments Off
Crazy Talk
Today, something frivolous. Perhaps you’re acquainted with Infocom’s 1983 classic, Planetfall? It’s a good game, but today I want to talk about its manual. Planetfall’s manual included a recruitment pitch/application form for the “Stellar Patrol”, and the form included a … Continue reading
Posted in Python
Comments Off
No-op KenKen Solver
A popular KenKen variant is the “no-op” puzzle, in which only the result of a cage is given. (In “standard” KenKen, both the result and an operator are given.) A reader wrote in with a question about a no-op puzzle, … Continue reading
Posted in Python
Comments Off