Tag Archives: Programming

Python first impressions

A few days ago I got my first Python project. I’d like to share references I’ve found, and what I like or dislike about the language. I hope to give insight to would-be Python dabblers and ideas to current Pythoneers.

Good resources I’ve found

I have found some good resources online for Python and Jython, but I know I didn’t find them all so if you Python-istas could put some in the comments I’d be very grateful :)

Continue reading

Programming lamentations to learn from

I was reflecting on some of the things I’ve experienced while in the software engineering field. There are some big mistakes I’ve witnessed and made. I’m going to share what they were and I hope you gain insights of how to approach some situations… especially if you are new to the industry.

Clever code

During my first job, I was helping to write a generic report builder application. We needed a method to parse a Date out of an oddly formatted string. Being fresh out of college, I was excited to show that I could write something that would parse immensely fast — and I did. There was one major problem, no one else understood it. When it came time to refactor, a senior engineer said this to me and I’ll never forget it:

Programming languages are designed to be understood by humans.

If your code is good enough to stick around it will have to be maintained and probably by someone else. There are exceptional cases of course, but remember that compilers often make the same optimizations (or better) than the ones you cleverly devised. Learn from my mistake, don’t be clever. Continue reading

Crush images on the command-line with Groovy

One of the ways to speed up your site and save bandwidth is to optimize your images. You can often halve an image’s size without losing (much) quality. Many photo editors may give you this option, but it’s a slow manual process. What we really need is a way to automate this so that every time we deploy changes we can optimize in one step.

Getting Started

You’ll need 2 tools (and Cygwin if you’re on Windows) to pull this off:

Continue reading