Presentation is loading. Please wait.

Presentation is loading. Please wait.

A compiler is a computer program that translate written code (source code) into another computer language Associated with high level languages A well.

Similar presentations


Presentation on theme: "A compiler is a computer program that translate written code (source code) into another computer language Associated with high level languages A well."— Presentation transcript:

1

2 A compiler is a computer program that translate written code (source code) into another computer language Associated with high level languages A well formed list of compilerscompilers Compiles Java source code into Java bytecode Translates all code at once Used with high level languages

3 In Java, the interpreter is a component of the Java JDK that runs Java bytecode classes Allows Java to be ran outside of a web browser Translates code one line at a time and then executes the instruction immediately Used with high level languages

4 Used with low level languages Basically this translates the low level language to machine code (then the program can be executed)

5 1. You create a source document using an established protocol (in our case, the Java language). 2. Then your program is run through a source code compiler. The source code compiler checks for errors and won’t let you compile until it’s satisfied that everything will run correctly. 3. The compiler creates a new document, coded into Java bytecode. Any device capable of running Java will be able to interpret/translate this file into something it can run. The compiled bytecode is platform independent. 4. The Java Virtual Machine (JVM) translates the bytecode into something the underlying platform understands, and runs your program.

6

7 Usually have to be either interpreted, compiled, or translated (or some combination of all three) Easier to use than low level languages Language is closer to spoken language Portable Abstract Examples: Java, Visual Basic, ?, ? (lab assignment)

8 In a sense low level languages speak the same language as the hardware Usually does not need a compiler or interpreter 1 st Generation: Machine Code 2 nd Generation: Assembly Language


Download ppt "A compiler is a computer program that translate written code (source code) into another computer language Associated with high level languages A well."

Similar presentations


Ads by Google