RSS

The other “Amazing Grace”

09 Dec

Today Google is promoting the birthday of Grace Hopper. Also known as “Amazing Grace” in some “old school”progLanguages programming circles. Grace Hopper is known as the founder of the independent programming language, which led to the development of one of the first modern programming languages, COBOL. If you’ve ever taken an Introduction to Data Processing of Computer Programming course you will have certainly heard of COBOL. Remember what the letters represent? COmmon Business-Oriented Language.

I read today that the COBOL language had to have been created by a woman because of it’s long form text. You know, women seem to have much more to say about any given subject than their counter gender parts.

Setting aside the gender stereo-types I’d like to give a comparison of COBOL and a more modern language like C#  or C Sharp. The example will be used in the same framework or environment such as Microsoft .Net. Each chunk of programming code will process a button to call an event named “COBOL”.

COBOL.Net

METHOD-ID. button1_Click PRIVATE.
DATA DIVISION.
LINKAGE SECTION.
01 sender OBJECT REFERENCE CLASS-OBJECT.
01 e OBJECT REFERENCE CLASS-EVENTARGS.
PROCEDURE DIVISION USING BY VALUE sender e.
    SET PROP-TEXT OF button1 TO "Call COBOL".
END METHOD button1_Click.

C#.Net

private void button1_Click(object sender, System.EventArgs e)
{
    button1.Text = "Call COBOL";
}

Notice the difference? Also notice the syntax? COBOL is rich in punctuation. Periods are key to the COBOL language, much like the braces (” {} “) in the C# language, they delimit the programming statements.

BTW, I believe C# was developed by a guy. 🙂

Advertisements
 
 

Leave a Reply

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

WordPress.com Logo

You are commenting using your WordPress.com 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 )

Google+ photo

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

Connecting to %s

 
%d bloggers like this: