Learning a computer language may be easier than you think
I have tackled French subjunctives and have conversed in Spanish, but it was not without some trepidation that I sat down recently to learn a new language: a computer language.Skip to next paragraph
Subscribe Today to the Monitor
It is not that I have never used a computer. Or that I dislike them. I use one to write whenever I can, and few things please me more than that wonderful ''delete'' button that leaves not a smudge as evidence of my inability to spell.
But learn a computer language . . . program a computer . . . that smacked of tinkering with a technology I don't pretend to understand.
So I was feeling a little nervous as I sat down at a terminal at Lesley College in Cambridge, Mass., for a lesson with Nancy Roberts, director of the school's graduate program in computers in education. And, I might add, a patient and reassuring person.
''Let's begin with LOGO,'' she said. ''That's fun.''
I took her advice. We began with a little LOGO and then we did a little BASIC. I survived. And I am here to tell the rest of you humanities majors hiding out there behind your bookcases that it was fun. And it was easy, a veritable cinch compared with memorizing irregular verbs.
A computer language, I learned, is not a secret code understood only by those who are comfortable with things called vector functions. No tangle of mysterious symbols appeared on the screen. In fact, the first thing my computer said to me was, ''Welcome to LOGO.''
''Oh good,'' I thought to myself. ''It speaks English. Must be one of those user-friendly models.''
Most computers are very friendly to their users these days, Ms. Roberts assured me.
We need to stop here for a minute and straighten out some things. We need to make the distinction between the human languages we all speak to one another and the computer languages. While there are similarities, they are not the same.
The language you use when you use a computer is English, at least in this country, whether the computer language is BASIC, LOGO, PASCAL, COBOL, or one of the other nearly 500 computer languages that have been invented.
The computer language is simply the set of words and the rules that mean something to the computer. Programming is using that computer language to teach the computer some new tricks (''Procedures'' is the word used by programmers).
When you get down to the basics, a computer is a mass of electrical switches that are either on or off.
''All a computer knows is that it is getting a signal or it is not getting a signal,'' Ms. Roberts said.
In the earliest computers those switches were turned on and off by hand, a tedious task, to say the least. The people who manipulate computers by turning the switches by hand are said to know ''machine language.'' As technology advanced and there were better ways to interact with the computer, so-called ''higher-level languages'' were developed. The word ''ADD'' came to mean the series of on-and-off switches that allowed or told the machine to add. The word ''PRINT'' was a different series.
A computer language is the particular shorthand you use that has already been taught to the machine.
The first program I wrote was one I have been told five-year-olds do with ease. I programmed the computer to make a square every time I told it to do so. That may not sound like much, but therein lies the essence of the whole business. First I typed in ''TO SQUARE,'' then I typed in the instructions, one step at a time:
FD 30 (meaning go forward 30 spaces).
RT 90 (make a right angle).
FD 30 (again).
RT 90 (again).
And so forth. It worked.
I did have to learn some vocabulary, some abbreviations, and some rules. I had to learn that hitting the return key was equivalent to closing my mouth. That was how the machine knew I had finished a thought. And I did have some bewilderment when the message on the screen told me to ''define'' or ''abort.''
I don't pretend to be proficient after my brief lesson, but I could see that competence was possible. Most people can become fairly expert in a comuter language with about a year of study and practice, Ms. Roberts told me. It is usually easier to learn a second or third language after acquiring the first.
One of the most confusing things about acquiring a computer language is deciding which one in this technological Tower of Babel to learn.
Although most people assume the first language they should learn is BASIC, it is not the best. ''It allows sloppy thinking,'' Ms. Roberts explained.
LOGO, which is an educational language, is better for getting a sense of what programming is all about, she said.
PASCAL, which is described as ''linguistically pure,'' has been chosen by the Educational Testing Service for college placement exams; FORTRAN is for scientists; and COBOL for the business world. PILOT is simplified BASIC.
There are already ''dead'' computer languages: SNOBOL and RPG II. And others are constantly being improved: FORTRAN is in its fifth revision.
If you want to be in with engineers, learn C, the hot new language that can be used with different machines. If you want to use the computer to write contracts for the Department of Defense, learn ADA.
Or don't bother learning any of them.
Learning a computer language isn't really very important for most people, Nancy Roberts pointed out. Other experts agree that with the number of software packages available, most people will be able to go out and buy whatever they need. If they can't do that, it will make more sense to hire a programmer than to learn to do it themselves.
There are benefits to knowing about programming, she said. But they are much like the benefits of knowing something about how your car works: useful, but not essential to successful driving.
The advantage to knowing a computer language and to being able to program is that it gives you more control over the machine.
''And,'' she said with a smile, ''there is a thrill to understanding what is happening.''