Preview

08 - Final Test

 1. An interpreter does not create an independent final set of source code - source code is created each time it runs.

  FALSE

  TRUE

 2. Interpreted languages include JavaScript, PHP, Python and Ruby. Interpreted languages are also called scripting languages.

  TRUE

  FALSE

 3. Java and C++ are compiled languages. Java is a high-level language which is compiled to produce bytecode which is then interpreted by a virtual machine (VM).

  TRUE

  FALSE

 4. Bytecode is code ….

   which is compiled and can then be interpreted.

  None of these answers apply

  which is bytesize in that it is always 8 bits long

  which is measured in bytes

 5. Libraries. These provide functions that are not included in the core part of the programming language and are IDE tools

  TRUE

  FALSE

 6. Name one example of a high level language

  Assembly Language

  Binary

  Python

  Machine Code

 7. What is meant by the term 'machine code'?

  Code in a format that the CPU can process

  All of the above

  Binary representation of instructions

  Made up of opcode and operand

 8. Maintaining a program is easier with High Level as opposed to Low Level languages

  TRUE

  FALSE

 9. Low level languages are closer to natural English

  TRUE

  FALSE

 10. What is the difference between machine code and assembly language?

  None of these apply

  Machine code has simple letters where as Assembly language has 1s and 0s

  There is no difference

  Machine code is binary / assembly language uses text. Machine code can be directly processed / assembly language must be translated/

 11. A compiler produces a machine code file but an interpreter does not

  FALSE

  TRUE

 12. What on the following list is a useful feature of an IDE?
•	Built in translator
•	Syntax highlighting / colour coding
•	Code completion
•	Automatic indentation
•	Automatic documentation
•	Error checking
•	Online help

  None of the items on the list are valid

  Syntax highlighting and Automatic documentation

  Error checking and Online help

  All of the items on the list are valid useful features of an IDE

 13. Both machine code and assembly language are machine specific

  FALSE

  TRUE

 14. Sometimes an IDE will suggest variable / function names while typing. What is this called?

  marrying IDE

  variable induction

  code completion

  helpful injunction

 15. Compiled code can be executed again without being re-translated … interpreted code needs to be translated each time it is run.

  TRUE

  FALSE

 16. Compiled machine code keeps the source code secret … interpreted programs mean that the source code is visible.

  TRUE

  FALSE

 17. Which language translator is used for low level languages?

  Assembler

  Interpreter

  Translatexutor

  Compiler

 18. Assembly language is made up of predetermined set of commands that can be understood by a human such as:

  print(Now)xx001

  101010101

  ADD

  xOR/One

 19. Each command 'word' translates ….

  directly into a machine code number

  directly into electricity signals

  directly into python code

  indirectly into programming code

 20. Assembly language has a low level of abstraction and is very similar to machine code (e.g there is a direct link between the instruction and machine code it represents)
Note: If you're really interested at this stage, perhaps give this video a watch (and try it out yourself)

  FALSE

  TRUE

 21. The complete set of commands available is called the _________________

  instruction set of the CPU

  mindset of the computer

  assembly junk of the operating system

  Fond butterfly code

 22. The instructions within assembly language are called Mnuecats

  TRUE

  FALSE

 23. Programming in asssembly language is considered:

  still quite difficult as the programmer needs to know about the hardware in the CPU

  the best sort of programming in use for web development

  the fastest approach to solving a problem that involves the internet

  incredibly easy

 24. One disadvantage or issue with assembly language is that the code only works on a specific CPU family. If you use a different CPU you would

  None of the above

  need to make a copy of your old CPU

  need to re-write the code using a different version of assembly language

  not need to rewrite the code at all

 25. The main advantage of assembly language is that it :

  runs slow compared to high level languages which makes it easy to follow

  is robust and hardy and cannot ever make a mistake (hence it's popular use in spacecraft)

  is soft and cuddly, and therefore programmer's favourite

  runs fast compared to programs written in a high level language as there is less code overall

 26. What is NOT used to translate high level languages?

  Assembler

  None of these answers apply

  Compiler

  Interpreter

 27. Which translator stops when it encounters an error and goes line by line?

  None of these answers apply

  Assembler

  Compiler

  Interpreter

 28. What type of translator is used to translate assembly language

  Assembler

  Compiler

  None of these answers apply

  Interpreter

 29. When working with a high level language, ________ needs to be converted into machine code to run in a CPU

  firmware software

  machine code

  embedded code

  source code

 30. Two tools that are necessary for both writing and converting high level language code are:

  Translators and Binary

  Translators and ASCII

  Translators and Currency

  Translators and IDEs