T8 - Translators and facilities: Flashcards

(35 cards)

1
Q

Machine code:

A

first computers,= all programs were written in machine code
Instructions = binary

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

machine code con

A

Difficult and time-consuming

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Assembly language: use

A

Device drivers are written here

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

assembly language function

A

allows a programmer to create programs more easily than writing in machine code

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

how assembly code works

A

Each instruction maps directly to machine code
- translated into machine code before it can be executed

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

assembly code features

A

processor-specific

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

assembly code meaning

A

Known as a low-level language = each instruction corresponds directly to a machine code instruction

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

High-level languages

A

generally have statements that look a bit like English or Maths

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

high level languages features

A
  • have data structures such as arrays and records
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

high level language pros

A
  • easier to learn and understand
    written faster
    easier to understand and debug
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

high level language works by:

A
  • translation is done by a program which may be either a compiler or an interpreter
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Low level languages pros:

A

run very quickly
require less RAM
used to control and manipulate specific hardware components (device drivers)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

compiler

A

translates a high-level language into machine code

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

source code

A

code written by the programmer

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

object code

A

the code produced by the compiler
saved to a storage drive and runs whenever required

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

interpreter

A

Program that translates a high-level language into machine code

17
Q

interpreter different to compiler - object code

A

Unlike a compiler, no object code is produced

18
Q

interpreter works

A
  • translates each line of code + executes it immediately
19
Q

interpreter pros

A

More portable = can run on any computer with an interpreter

20
Q

what happens if an interpreter reaches a line with syntax error

A

it stops and displays an error message

20
Q

compiler translates to produce

21
Q

interpreter translates and executes

A

one line at a time

22
Q

compiled program speed

A

faster as it is already in machine code

23
Q

interpreter speed

A

Takes more time to execute as
each instruction is translated
before it is executed

24
does compiler always have to be installed
No need for the compiler to be present when the object code is run
25
does the interpreter always have to be installed
interpreter must be installed to run the program
26
customers and compilers
Customers who have bought commercial software cannot see the code when they buy it so cannot adapt it
27
customers and interpreters
Customers can see the source code so could adapt it or see how it works
28
Bytecode
can be interpreted on many different types of processor using an interpreter
29
bytecode meaning
Some languages, such as Java, are compiled into this intermediate stage
30
bytecode javascript eg
is interpreted; the source code is included in the web page and then interpreted in the browser
31
java script use
used in creating web pages,
32
High-level languages include
Python, VB and Java.
33
High-level languages need to be
compiled or interpreted before they can be run. Assembly language is a low-level language. It is assembled into machine code before it is run.
34
Assembly language is a
low-level language. It is assembled into machine code before it is run.