all items
rss feed

/ \
Ugh, stop twitching
coding in english
coding Posted 2003-05-07 11:23:10 by Jim Crawford
There seems to be a common meme floating about, that designing a programming language so that it looks like English makes it easier to learn. In this essay, the author intends to demonstrate that this idea is fallacious.

There are plenty of lousy-yet-popular languages out there that are similar to English. This kind of language can be considered a subset of the English language -- that sounds pretty good, doesn't it? You already know it all, right?

Well, not really. You can approach such a language this from one of two directions: you can build up, from zero assumed knowledge, or you can cut down, from assumed knowledge of the natural language.

How feasible do you think the latter approach would be? There are dozens of grammatically correct ways to express the conditional statement “if x is equal to y then do z.” Only one will work in Subset-Of-English. And that's just at the syntax level -- before you even got to the details, you have to learn that you can't just ask the computer to “make the ball bounce.”

No, the only feasible approach to learning such a language is the build-up approach. In which case, what's the advantage of Subset-Of-English over a language with syntax that's designed from the ground up, specifically for programming?

There is one: it's easier for non-programmers to read and understand. This has probably led a lot of non-programmers to choose a language like this. But if you're going into programming, you're probably going to be a programmer a lot longer than you're a non-programmer. Wouldn't it be wiser to choose a language that's optimized to make life easier for programmers?

In conclusion, the author has demonstrated that it is fallacious to design a programming language to be similar to English in order to make it easier to learn.

By the way, on a syntax level, “making life easier” for programmers generally means making the code more concise. This is becauese concise code takes less time to type and less mental effort to parse.

[link to this] [See more on “coding”]

not true! [note to non-programmers]
Posted by AdamMil on 2003-05-08 10:21:17
That's just not true! Compare these two programming languages:

Perl, a hacker favorite. Here's what you do in Perl if you want to print your name. I'll assume your name is Peter Barabas.
Hackers just love that stuff. It must make them feel so superior. Now let's consider BASIC, an English-like language scorned and hated by hackers everywhere for its wonderful simplicity. This basic program does the exact same thing.
print "peter barabas"
BASIC may not be as "c00l" or "L33T" or "phAt" or whatever those hackers consider Perl to be, but I'll leave it to you to decide which is the better language.

Long live BASIC!!!
one of many many ways...
Posted by Anonymous (Benjamin S. Wiegele) on 2003-09-06 04:14:57
this is just one of so many different ways to print a string in Perl.
we could use
print "Peter Barabas\n";
as well...
Posted by Anonymous ( on 2003-10-24 21:02:12
Actely, Perl and BASIC is both beter, but programming language so that it looks like English is no good. And I dont understand how the top perl things works. I tryd it, and it dus work, but I dont understand Perl anuf to understand wy it works.
add a comment
Only anonymous comments are available for now until I get the user system up and running again. Not many people were logging in anyway, so enh.
Permitted HTML tags: <b>, <i>, <u>, <tt>. Also permitted is the <q> pseudo-tag which is meant to delimit quotes from other messages.
To prove you are sentient, please type "sentient" into this box

what's this?
This is Jim Crawford's blog. Details and contact information.

On Twitter: @mogwai_poet

recent comments
Overview (Anonymous on may 2014 microblog digest)
no subject (Anonymous on troboclops - hate edge)
no subject (Anonymous on troboclops - hate edge)
hp printer support phone number (Anonymous on troboclops - hate edge)
great (Anonymous on take a key for coming in)
Thank you very much (Anonymous on take a key for coming in)
Astrologer for Love Problems (Anonymous on troboclops - hate edge)
Hp Printer Support Phone Number (Anonymous on troboclops - hate edge)
Please visit site (Anonymous on troboclops - hate edge)
Please visit site (Anonymous on troboclops - hate edge)
Please visit site (Anonymous on troboclops - hate edge)
Please visit site (Anonymous on troboclops - hate edge)
Job Astrology (Anonymous on may 2014 microblog digest)
Finance Astrologer (Anonymous on may 2014 microblog digest)
SOURABH (Anonymous on troboclops - hate edge)
Comments RSS