Perl Power

xkcd #208

My job at the UHM School of Nursing and Dental Hygiene Office of Student Services requires me to deal with a lot of csv files. When I took ICS 111, I hoped that I would learn how to deal with them better. For years I massaged the data into a more malleable format so that I could append the data into my Microsoft Access database. Thankfully, we learned about parsing, but not how to deal with file systems in Windows. Eventually, I figured out away to write a Java program to do almost everything I wanted, but not entirely. Then I took Introduction to Scripting and learned just enough Perl and Regular Expressions.

The first program I wrote for work using my new found Perl and Regular Expressions skills allowed me to “massage” all the nursing class roster data stored in a batch of csv files that I downloaded into a single csv file. Before I learned to proram in Java, it would have taken me hours to “massage” all the data using Excel. While I could have updated by my Java version of my program to include regular expression, the Perl version of my program was shorter and easier to follow. A simple Perl program does not require all the boiler plate code required by Java, nor the use of objects. I continually amazed how much easier and faster it is prototype a program in Perl compared to Java. In addition, the online documentation for Perl is much easier to follow. Amazingly, it only took me a day to convert all my other Java files into Perl scripts, but that should not be surprising since Perl was initially developed to help parse text. Perl’s creator, Larry Wall, developed Perl to specifically deal with complex text parsing that he was not able to do in the AWK programming language. Since its inception, Perl’s been development has been guided by a programmer first philosophy. What makes Perl truly exceptional is that it feels like a languages designed by programmers for programmers to get work done. And I can think of no higher praise than that.

The Perl Onion is trademarked to the Perl Foundation.