An area where python really shines is in the making of small apps with graphical interfaces. So, considering how much effort went into creating a GUI in OpenGL (you can check out my C/C++/C# portfolio for more info on that project), I decided to write an app for my library catalogue in python.
The idea behind the project was to convert an old excel-file containing all my books into an SQL database and be able to add more books to it and make it searchable. Existing frameworks in python make this quite an easy thing to do and I had a working GUI doing all these things within about six hours, even though it was the first time I tried my hand at tKinter. Then, of course, I had a bit of feature creep and some polish, taking at least as much time again.
I took advantage of the fact that SQL commands are incorporated as strings to make a dynamic search engine for my database (that sounds a bit more like I am trying to sell something than I intended):
I also decided to open search results in a new window. Similarly, adding a book opens a new window. In essence, opening new windows is lot easier than tearing down all GUI-items and building everything up again every time a button is pressed. In a program such as this, it is also more user friendly with new windows since the user can make several searches according to various criteria while still having access to the old results. It also allows for a peek at formatting when entering details for a new book.
You may have reacted at the varying entry lengths when adding books. They are based on the longest entries I had in my excel-file. The longest title is, incidentally, Hooke's Micrographia when you include the sub title. At any rate, adding books from a new window also meant that I was required to use a lambda to call the add button's command function.
I mentioned feature creep, didn't I? Well, I decided it would be nice to be able to change a few things for the user, such as what database file is displayed on startup. So I made a settings page that writes to a config file that the program reads on startup. Here, you can also change the character length of entry fields which is also the character length of the search result fields.
All in all, nothing really groundbreaking but I'd say a clear demonstration of the ease of use with python, effortlessly blending GUI, SQL and CSV to create a useful program with just 400 lines of code. I'd like to point out that I prefer writing as simply to read as possible. I'm not a fan of various flavours of syntactic sugar.