Languages & Translators

Cards (27)

  • What are the two types of programming languages used in computer systems?
    High-Level Languages and Low-Level Languages
  • Why do programmers use high-level languages?
    They resemble natural human languages for ease
  • What is a benefit of using high-level languages compared to low-level languages?
    They lead to fewer errors and complex commands
  • What must high-level languages be translated into before execution?
    Machine code (binary)
  • When are low-level languages typically used?
    When programs must execute quickly or interact with hardware
  • What is machine code?
    Pure binary code that computers can execute
  • Why is machine code difficult for humans to understand?
    It is extremely tedious and complex
  • What is an advantage of using machine code?
    It executes faster than high-level programs
  • What does assembly language use to perform actions?
    Specialized command mnemonics
  • Why do many programmers prefer assembly language over machine code?
    It is easier to understand and spot errors
  • What is the role of a translator in programming?
    To change a program from one language to another
  • What is the difference between an interpreter and a compiler?
    An interpreter translates one line at a time
  • How does an interpreter execute code?
    It converts high-level code into machine code line by line
  • Why is an interpreter slower than a compiler?
    It must reinterpret code each time the program runs
  • What is a key feature of compilers?
    They produce an executable file for later use
  • What happens to the code after compilation?
    It can run on other machines without recompilation
  • What is the error reporting method of a compiler?
    It analyzes the entire program and records errors
  • Compare the execution method of interpreters and compilers.
    Interpreters translate line by line; compilers all at once
  • What are the key differences between interpreters and compilers?
    • Execution Method:
    • Interpreter: Line by line
    • Compiler: All at once
    • Execution Speed:
    • Interpreter: Slower
    • Compiler: Faster
    • Complexity:
    • Interpreter: Smaller, simpler
    • Compiler: Larger, complex
    • Error Reporting:
    • Interpreter: Immediate reporting
    • Compiler: Reports after analysis
    • Repetition:
    • Interpreter: Requires re-interpretation
    • Compiler: Compiled once, recompiled after changes
  • What is the specification code for the OCR exam board mentioned?
    J277
  • What is the section title that includes Assembly Language?
    1. 1: Languages & Translators
  • What is the purpose of the Assembly Language section in the programming tab?
    To list mnemonics like INP, OUT, HLT
  • What is a benefit of using assembly language instead of machine code?
    It is easier to understand and debug
  • What is a benefit of using assembly language instead of high-level language?
    It is faster to execute than high-level languages
  • Compare high-level and low-level languages in terms of ease of understanding.
    High-level languages are easier to understand
  • Which type of language requires translation before execution?
    High-level languages require translation
  • Which type of language is quicker to execute?
    Low-level languages are quicker to execute