In my previous post, I have shared some of the basic definitions about programming languages with examples. These are the very basics things to be known before learning any language. Now, let us take an other step forward.
You can never understand a movie of another language without a subtitle or a translator. Similarly, different people prefer different programming language of their own choice. It is not possible for a computer (a machine) to understand any language without the help of some translator.
As I mentioned earlier, Computer can only understand the machine language i.e., a stream of 0's and 1's. So, once you complete the program, there must be a way to convert it to the machine language. Then only, it can be understood by the computer.
WAYS:
The input here is the program and the output is the machine language. There are two ways to do this-
1. COMPILER : Compiler takes the entire program as input and also generates intermediate code. Due to this, memory requirement is more but it can handle conditional statements in a faster way. The errors will be displayed only after the entire program is checked. eg: C
If you do not have a compiler, you can write and compile c program online .
Intermediate code: The source code is most commonly converted into assembly code, which in turn is converted into the machine language by the assembler. eg: gcc
Byte code: The byte code is formed as the intermediate code here and this code will run on host machines. eg: javac
2. INTERPRETER : Interpreter converts the program to machine language line by line. It does not generate any intermediate code. And so, memory requirement is less. It can not handle conditional statements in a faster way. The errors will be displayed after each line is processed. eg: BASIC
IDE - IDE stands for Integrated Development Environment
It is not just the tool where you can write your programs, it provides a way to compile and debug it. It reduces the stress of the programmer. eg: NetBeans, eclipse, etc.
Tags: Compiler, Interpreter, IDE, Text editor, Intermediate code, Byte code, online C compiler,
Copy Article URL:
No comments:
Post a Comment