Which language is right for you?

By Cameron Laird and Kathryn Soraiz, Unix Insider |  Development Add a new comment

Pick the language with which you're most comfortable. That's our advice to reader John Wiersba, who asked us several weeks ago where he should concentrate his study.


Selection principles

For the most part, Regular Expressions concentrates on general principles or concepts that are likely to apply to several scripting languages: inter-process communication, character encodings, graphical toolkit bindings, concurrency, and so on. Three and a half years ago, though, we did a feature article, "Choosing a scripting language," when Unix Insider was still SunWorld. It's time to update that piece.


Wiersba's question is a good one. He wants to make the most of his education and experience, so he's looking for a language that won't limit him. Rather than learn several poorly, he's out to concentrate on one and get to know it well. Which one deserves his time and attention?


The technical capabilities of most of the popular modern scripting languages have converged remarkably, even over the three years that we've been writing Regular Expressions. You can largely expect to be able to do the same things with Perl, PHP, Python, Rexx, Scheme, Tcl, and other such languages: script dynamic Webpages, build administrative utilities, prototype graphical user interface applications, glue together legacy data and processes, and so on. You can code in procedural, object-oriented, or functional styles. You can expect to be able to run your scripts on Mac OS, Unix, or Windows. You can manage other processes, and script Java and COM objects. You have limited access to hardware such as serial ports, but you can extend built-in capabilities with C or other languages. Internationalization is possible and often practical. You can freely reuse any of a staggering number of modules other programmers have written.


Therefore, our first answer is to use what feels comfortable to you. If Python's use of white space makes your skin crawl, learn Ruby instead. If you want to get along with your coworkers without having to explain your Tcl or Forth mentality, you might find them ready to accept Perl or Pike. You'll be able to create roughly the same functionality no matter which language you use.


Collect your own data, talk to the natives

The successes in language choice are often instances in which a programmer gets along well with the other natives. What's most important about Perl is probably not the syntax of the language or its constellation of command-line arguments, but the cultural system of the Comprehensive Perl Archive Network (CPAN) -- maintained perldocs, good conferences, local PerlMonger meetings, and so on -- that makes practitioners feel they've found a home.


One of the most pleasant aspects common to these languages is that you can take them out for a spin inexpensively. Locating a language processor and documentation, downloading them to a host you control, and writing your first sample program usually fits within a conventional lunch break. There are extensive online information archives available for all these languages. Rather than flip a coin or trust an expert to decide, you can quickly acquire your own sense of how different languages work.


Each language does have limits. Their analysis, though, has become exceedingly arcane. Advanced use of Python, for example, rests crucially on its aesthetic for introspection and its promotion of metaprogramming. Is that the right approach for you? There's almost no adequate way to judge this without the subtle understanding of you and your work that no one else is likely to have.


Still, we can give you a starting point. If you follow one of our recommendations, and it takes two years to find out that another choice would have been better, we'll feel successful.


Scouting notes

Here's what we think about the leading portable scripting languages:


Perl: Perl outranks all the others quantitatively. More job seekers claim Perl experience, and more companies advertise its use, than all the others combined. Perl is powerful, but not easy. Perl is ubiquitous in Web work and Unix system administration. Greatest liability: extending Perl with C is tedious, and with Java an adventure.


Python: Python's grown rapidly over the last couple of years. Python has no particular weaknesses: It's a great language for beginners, it's a great language for large projects and teamwork, and it enjoys a breathtaking array of convenient accessories. Python is the one language with which we feel safe in recommending for all situations.

    Add a comment

    Post a comment using one of these accounts
    Or join now
    At least 6 characters

    Note: Comment will appear soon after you have activated your account.
    Obscene/spam comments will be removed and accounts suspended.
    The information you submit is subject to our Privacy Policy and Terms of Service.

    ITworld LIVE

    DevelopmentWhite Papers & Webcasts

    White Paper

    HP NonStop SQL Fundamentals whitepaper

    This whitepaper offers a detailed look into the fundamentals of HP NonStop SQL solutions. See how this system delivers unprecedented levels of application availability with fail-safe data integrity and meets the needs of enterprises with large-scale business critical applications.

    White Paper

    Nebraska Medical Center case study

    See how the Nebraska Medical Center implemented a SQL solution to make information more readily available to streamline operations, improve patient care and facilitate medical research with an enterprise solution running on HP NonStop servers.

    White Paper

    Concepts of NonStop SQL/MX

    For DBAs and developers who are familiar with Oracle solutions and want to learn about NonStop SQL/MX, this whitepaper provides an overview of the similarities and differences between the two products-with a specific focus on implementation.

    White Paper

    6 Things Your CIO Needs to Know About Requirements

    If your organization is not predictably successful on technology projects, there is likely an issue in requirements. CIOs must take action and own requirements maturity improvement. There are 6 main things a CIO must know about requirements.

    Webcast On Demand

    User Experience Monitoring

    In this webinar, you will learn hints & tips for improving end-user response times from Forrester Research analyst, Jean-Pierre Garbani.

    Sponsor: Nimsoft

    See more White Papers | Webcasts

    Ask a question

    Ask a Question