Creating a Program

What Is Programming?  

Computer programming is the process of developing lists of instructions. To make the computer do any complex or meaningful task, thousands or millions of instructions may be required.

In the early days, computer programmers developed software by directly writing instructions. This would be equivalent of telling a person to pick up the phone by detailing which muscle to use and how much to flex it.

Now, programming languages make it easier to tell the computer what to do. Using the previous example: Instead of detailing which muscle to move and how much, the programmer can simply say “Pick up the phone.”

A natural language can be thought of as a standard or an agreement on how things are expressed (e.g., English, Spanish, Japanese, French, etc.). In the same way, there are many programming languages that have their own way of telling the computer what to do. Note the following examples on how to write a program to say “Hello world” using different programming languages:

Programming Language

Programming Code

COBOL

IDENTIFICATION DIVISION.
PROGRAM-ID. HELLO-WORLD.
PROCEDURE DIVISION.
      DISPLAY ‘Hello world’.
      STOP RUN.

Fortran

program helloworld
    print *, “Hello world”
end program helloworld

C++

# include <iostream>
int main ()
{
std::count <<”Hello world”\n;
>}

Java

class HelloWorldApp{
    public static void
    main(String[] args){
         System.out.println(“Hello world”);
    }
}

So why are there so many different programming languages? Different programming languages are designed to do certain tasks easily. Here are examples of older languages and modern languages and their uses:

Programming Language

First Developed

 Purpose

BASIC

1960s at Dartmouth

Example of an older language. BASIC was a Beginner All-purpose Symbolic Instruction Code. It was designed to make it easy to write simpler programs.

Fortran

1950s by IBM

Example of an older language. FORmula TRANslation. It was designed to easily create complex formulas in scientific or engineering applications.

C++

1980s

Example of a modern language. C++ was designed to exert detailed control over the computer. It is used to create most microcomputer-based software packages today.

Java

1990s by Sun Microsystems

Example of a modern language. Java was designed to be “platform independent” so that one version of the source code can run on many computer platforms without modification.

Who designs a programming language? Typically, a programming language is created by one of two types of designing bodies: a consortium or a company.

Consortium: A consortium of interested parties under the umbrella of a standards-setting body.  C++ was standardized under the International Standards Organization (ISO).

Company: A powerful company such as Sun Microsystems (since absorbed by Oracle) developed Java, and the company largely controls the language .

The programming process is as follows:

  • A programmer writes the program, and the result is known as a source code.
  • Then, a piece of software (usually known as a compiler) translates the source code into the instructions that the computer understands.
  • The result of this operation is a file that can be called several things: object code, or executable, or application or app.

References

Backus, J. (October–December 1998). The history of Fortran I, II, and III. IEEE Annals of the History of Computing, 20(4), 68–78. doi:10.1109/85.728232.

Byous, J.(c. 1998). Java technology: The early years.  Archived from the original on April 20, 2005. http://java.sun.com/features/1998/05/birthday.html

Kurtz, T. E. (2017) History of programming languages. http://cis-alumni.org/TKurtz.html

Stroustrup, B. (2010). When was C++ invented? In Bjarne Stroustrup's FAQ. http://www.stroustrup.com/bs_faq.html#invention

Check Your Knowledge

Question 1
Humans need programming languages because they _________
make communications between programmers easier
make communications between computers easier
make it easier for humans to instruct the computer what to do
all of the above
Question 2
Which of the following is not a programming language?
UML
Java
C++
All of these are programming languages.
Question 3
Programming languages differ in ___________
syntax complexity
target application
required hardware
all of the above
Question 4
________ is the name of the programming language developed by Sun Microsystems in the 1990s.
Latte
Mocha
Java
none of the above