First programming language – multiple languages anyone?

So most courses which teach introductory programming teach one language. Or at least they do now. Many years ago, before the 1980s, courses on introductory programming did not necessarily focus on any one particular language. In some cases they taught the craft of programming using algorithmic languages based on some Algol-like syntax. In other cases they taught concepts by looking at how they were implemented in multiple languages. That’s right multiple languages. Introductory courses weren’t just about concentrating on the syntax of C, Java or Python. Is there any reason why one couldn’t teach the notion of decision statements and illustrate them in two, three or four languages? Or loops? Or modularity for that matter?

The simple answer is no. We should be teaching introductory programming courses which concentrate on programming artifacts and use languages to illustrate these artifacts. Which languages? Who cares – choose a bunch – C,  Ada, Fortran, Python. Just make sure they are somewhat different in their structure, don’t just choose C, C++ and Java – they’re all have the same ancestry (i.e. C). Consider a simple for loop. In C:

for (i=1; i<=100; i=i+1){
    x = x + i;

in Ada:

for i in 1..100 loop
    x := x + i;
end loop;

in Fortran:

do i = 1, 100
    x = x + i
end do

or in Python:

for i in range(1,101):
    x = x + i

The syntax may be different, but the end result is the same.


One thought on “First programming language – multiple languages anyone?

  1. robodas says:

    Thanks for the insight! I have noticed that even past intro classes, some universities have “favorite” programming languages that seem to be promoted in further classes like algorithms, data structures, etc. This does give programmers a very limited impression of programming – don’t you think?

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.