Saturday, January 29, 2011

Project 4 - Advantages and disadvantages of programming languages

Project 4 - Advantages and disadvantages of programming languages


This blog posting gives a review of the different broad categories of programming languages. It should be noted that there is no central body that oversees the taxonomy of programming languages, so what is presented here is an overview depicting a popular understanding of the different programming languages and how they relate to each other. It is very easy to find well respected texts and articles that place languages into different systems of categorization. It turns out that the world is not black & white, but a continuous spectrum of grays....

Lowest Level Languages

Machine Language and Assembly Language are the least readable to human beings, and the most readable for computer systems.

Machine Language
Processors and micro-controllers communicate digitally in the form of sequences of 1's and 0's, in bits, bytes. Often displayed in hexadecimal format, each byte of machine language represents a single addressable location in memory. Machine language, also called machine code, being the direct digital input and output of a processor, is the lowest level language available to a programmer.
Advantages:
1.      Lowest memory consumed for the code to be executed
2.      Fastest programming language do the lack of processing layers
3.      No additional translators are needed between the machine code and the processor
Disadvantages:
1.      Extremely difficult to learn, write, and debug
2.      The code is very dependant on the hardware configuration it is being run on
3.      There is no process for tracking memory locations used by the machine code
Example:
        8086 Processor Machine Language
References:

Assembly Language
Assembly is a group of computer languages that map to micro-processor families. Assembly directly makes calls to the memory and processor hardware it is running on, resulting in a very fast running code. An Assembly language is very specific to the processor vendor, and very difficult to learn.
Advantages:
1.      High Speed processing compared to any higher level language
2.      Easier error correction compared to raw machine language
3.      There is the potential to leverage specific processor capabilities that may exist within the vendors support of an Assembly language.
Disadvantages:
1.      Machine dependant, not portable to other platforms
2.      Requires in-depth knowledge of the hardware the program will run on
3.      Slower than raw machine language
Examples:
        Macintosh Assembly System, to run on the original Motorola CPU sourced Apple Macintosh computers
References:
        Machine Language For Beginners, y Richard Mansfield, published 1983, http://www.atariarchives.org/mlb/introduction.php
        OSData.com - Introduction to Assembly Language - http://www.osdata.com/topic/language/asm/asmintro.htm

High Level Languages

A High Level programming language is a more human readable programming language than something that must be directly read by a micro-processor. High level programming languages are not directly dependant on the underlying processor location, but rather focused on more general purposes. This abstraction from the underlying processor is often handled by a compiler.
References:

Current Mainstream High Level Language Types

The following are four families of modern high level languages.

Procedural Languages
Synonymous with Imperative Programming, Procedural Programming follow a process of procedures, or functions, to interact with data. The programming routines are segregated from the data being manipulated. At its simplest, a Procedural language creates a series of procedures that the application carries out specific operations.
Advantages:
1.      Very well understood programming paradigms, with a broad range of programming languages and developers available
2.      Easier to quickly understand the flow of an entire application on inspection of the code.
3.      Easier to quickly develop smaller solutions, in comparison with O-o languages
Disadvantages:
1.      Lack of re-usability of the code being developed, for other applications.
2.      Troubleshooting challenges due to the lack of encapsulation of code with data
3.      Lack of flexibility
Examples:
        Basic
        Python
References:

Object Oriented Languages
Object Oriented Languages (O-o) are characterized by a modularity of design and function, maximizing the ability of a developer to re-use code from one project to another. Instead of segregation of code from data in O-o programming, these two are bound together into a single object of code.
Advantages:
1.      Designed to optimize the re-use of code from one application to the next.
2.      Objects require a higher level of documentation than other languages, and are therefore easier to maintain.
3.      Modification of software is easier through the modification of individual objects, or the introduction of new software objects.
Disadvantages:
1.      Lack of support from vendors, as well as lack of knowledge from programmers, due to Object Oriented Languages often being new to the marketplace
2.      The ease of stringing together O-o modules often encourages groups to bypass the traditional software design methods necessary to create a cohesive software package
3.      O-o design requires a different mindset than that used by Procedural Languages
Examples:
        C+
        Java
References:

The Obscure High Level Language Types

Functional Languages
A Functional Programming Language takes the form of single expressions that result in a function completing a task.
Advantages:
1.      Very Quick to learn
2.      Very easy to troubleshoot
3.      Very concise code
Disadvantages:
1.      Not well suited for high performance applications due to the abstraction and calls to function libraries that need to occur “under the hood”
2.      Requires a different set of programming skills from Procedural programming environments
3.      Not well suited to applications that require a Graphic User Interface (GUI)
Examples:
        SQL Query Language
        Haskal
        Skala
References:

Logical Languages
Logical Programming Languages, as the name suggests, are structured around mathematical logic constructs.
Advantages:
1.      Allows for rapid prototyping of tasks by creating lean programs to simulate logical phenomenon.
2.      Well suited for analysis of complex problems that involve logic sets
3.      Easier direct translation of mathematical notation into a program
Disadvantages:
1.      Very esoteric language with limited programming community knowledge and support
2.      Does not support GUI based requirements
3.      Code is rarely reusable, requiring application to be written from scratch each time.
Examples:
        Prolog
        LDL
References:

Language of the Future


Currently, Python is the language of the future. It is being taught in some of America’s best universities as a foundational computer science language, used by Google and other leading Silicon Valley companies as a core development language, and is increasing in popularity over time on the TIOBE Programming Community Index. For the last ten years, in fact, Python has been increasing in popularity faster than any other language.

No comments:

Post a Comment