Search Header Logo
Translators

Translators

Assessment

Presentation

Computers

12th Grade

Practice Problem

Easy

Created by

Missus Dighton

Used 27+ times

FREE Resource

11 Slides • 8 Questions

1

Translators

N5 Computing Science

Slide image

2

High Level Languages

  • Programs written in a language similar to English

    Python, Java, C#, HTML, SQL

  • Advantages

  • The commands use English keywords such as PRINT, INPUT, WHILE etc. which are easy to understand

  • Complex arithmetic can be performed in one instruction that would take many machine code instructions

  • They have in-built mathematical and logical functions to process the data

3

But what do Computers Understand

????????

4

Computer Understand Machine Code

  • Machine code is the computer’s own programming language, made up of binary codes to represent the program or instructions.

5

We need to translate for Computers

From High Level Language to Binary Machine Code

6

This is done by Translators

  • There are 2 types of Translator

  • Compiler

  • Interpreter

7

Compilers

  • A compiler translates the complete program (source code) into object code (machine code) in one go before the program is run.

  • Compiled programs run faster since there is no translation at run time.

  • It produces stand-alone machine code program which runs by itself without the need for the source code and the compiler

8

Interpreter

  • An interpreter translates and executes source code programs one statement at a time into machine code while the program is run

  • It will run more slowly than a compiled program due to executing the program one line at a time.

  • Execution will stop immediately if the interpreter translates a line of source code that results in an error making it easier to spot errors in the code

9

Let's see if you've understood

????????

10

Multiple Choice

Which of these could be machine code?

1

print ("01011011")

2

01011011

3

code = int(input("Enter code")

11

Multiple Choice

Which of these is an example of a high level language?

1

Binary Machine Code

2

Python

3

CSS

12

The next few questions will have an answer of either Compiler or Interpreter

Let's play which translator!!

13

Multiple Choice

This translator program reports errors at the end of translation.

1

Compiler

2

Interpreter

14

Multiple Choice

This translator needs to be present in memory each time the program is executed.

1

Compiler

2

Interpreter

15

Multiple Choice

This translator runs more slowly due to executing the program one line at a time.

1

Compiler

2

Interpreter

16

Multiple Choice

Using this translator means that the source code program will only be used again if the program needs to be changed.

1

Compiler

2

Interpreter

17

Multiple Choice

This translator will stop program execution immediately if it finds a line of source code that results in an error

1

Compiler

2

Interpreter

18

Multiple Choice

Last one!!!


A program which has been translated using this type of translator will run faster

1

Compiler

2

Interpreter

19

Summary of Translators

  • Use an interpreter when debugging code


  • Once code is error free, use a compiler.

Translators

N5 Computing Science

Slide image

Show answer

Auto Play

Slide 1 / 19

SLIDE