Tuesday, July 29, 2014

Languages : How a computer understands different languages

We know that you can write computer programs using different computer languages such as Java, C. But the problem is how the computer understands all the instructions given in those languages. It is very simple to understand when we think a computer as a living object.

Each and every one of you have a mother language. You can understand instructions which are in your mother language without any problem. Computers also have a mother language. It is machine language (known as binary language, alphabet with 1s and 0s). Computer can understand instructions which are in machine language.


As you grow you will learn different languages(for an instance : French). After you have learnt french you will understand french instructions also. You will receive the french instructions and you will translate it into English or into your mother language. Then you know what to do. You will act according to the instruction. In computers, same thing happens. You give instructions to the computer in JAVA. JAVA compiler will translate your source code in to machine language. Then computer understands the instructions.

That's why you need a compiler and that's how a computer understands different languages. It is more like you learn a different language.

No comments:

Post a Comment

Salesforce Metadata Deployment

Salesforce Metadata Deployment What are metadata? Let's understand this through a simple example. Imagine you are a Salesforce Admin an...