Ever
wonder how people ever came to the point where they could build a cnc
machine (A very advanced tool that can make highly complex parts down
to accuracies of about 1/1000s of an inch or even more)? Well it
started like this; Man creates fire. Man uses fire to melt together
pieces of iron ore. Man adds burned wood (carbon) to iron to make
steel. Steel is good, but not straight. How does man make straight
steel. Well, man knows taut string make perfectly straight line. Man
bangs metal until aligns with string. Man covers steel with oil to
reduce rusting. Man uses new steel workbench to make better and
straighter tools. Man .... etc...
So, you use one thing to
leap-board you to another, better thing. Programming is the same way.
The first programs were basically written by studying an extensive
manual that had all of the instructions that the CPU would recognize.
You would enter those instructions one by one (hitting enter after
each instruction) until you built your own program. Most computers
did not have a way to save information permanently so you had to
rewrite your programs every time you booted up. Oh by the way, when
you say booting up, you're referring to the term: "pulling
yourself up by your bootstraps". This was a very laborious and
time consuming business. Most keyboards had very well engineered 0,
1, and enter keys. Oh, you thought people would program with words?
Nah, words were for losers. The only language around was that of the
CPU (Binary instructions).
Well, the coolness wore off and
hard drives were created and prices eventually dropped. With a hard
drive, a translator could be programmed in binary that took words
typed into the computer, and translated them into binary
instructions. This translator was called a machine code compiler and
the language for it was called Assembly. Assembly is different for
every architecture. You cannot write a program in Assembly for one
CPU and expect it to work on another. Assembly was used to make the
first true universal languages that would work on multiple
architectures. One of these languages was C. C is what is called a
low level language that led the way for much more advanced operating
systems and programs. C was still very obscure however and large
programs were hard to manage. That's where C++ came into play. C++ is
what is called a high level language that allowed software developers
to create programs that were huge compared to programs written in C.
C++ was one of the first languages to incorporate object oriented
programming. A programming style that is widely used today. It
basically means, that most data has a "type" that is
"handled for you". For example. In c, you would tell the
computer to store the number 18 in a specific location in memory.
Then when you would want that number, you would have to remember (or
have it written down) where that location was. In C++, you could just
make a variable, and have some implemented system handle the rest for
you.
Even simpler languages were made to help speed up
development time but most are not translated into binary like
Assembly, C, and C++ are. They instead are interpreted as they are
executed. When looking at a completed program in C++, the data is
simply 0s and 1s because it was translated to that. When looking at
higher level interpreted languages like GML, you see written code
(words and such) because they are not translated before they are run.
Every interpreted language has what is called a, you guessed it,
interpreter. The interpreter is a program that takes meaning from the
code you write, and executes it in its own way. This is why
interpreted languages are generally slower than compiled (translated
ahead of time) languages. Come to think of it, I'm not really sure
why every interpreted language isn't compiled. I guess that means
this article isn't finished. Oh well, Ill leave you with this
chronological list of coding language types.
Binary
instructions
Assembly
Low
Level
High
Level
Interpreted
|