Classifying programming languages and translators

Cards (52)

  • What do high-level languages allow programmers to do?
    Write instructions in an easier language
  • What is the role of translators in programming?
    Translate high-level languages into machine code
  • What are the characteristics of high-level languages?
    • Easier to understand than low-level languages
    • Closer to natural language
    • Require translation into machine code
  • What is machine code?
    Low-level language directly understood by CPU
  • How is machine code represented?
    As a series of binary numbers
  • What is binary?
    A number system with two symbols, 0 and 1
  • Why do programmers find machine code difficult?
    It is hard to learn, program, and debug
  • What are programs in programming?
    Sequences of instructions for a computer
  • What is a high-level programming language?
    A language used to write computer programs
  • What do high-level languages need to be translated into?
    Machine code through a compiler or interpreter
  • What do high-level languages allow programmers to focus on?
    What needs to be done, not how
  • What are common high-level programming languages?
    • Python
    • Java
    • C++
    • C#
    • Visual Basic
    • JavaScript
  • What is source code?
    Instructions written in a programming language
  • What must source code be translated into?
    Machine code for execution by a computer
  • What do high-level languages allow programmers to do?
    Write instructions in an easier language
  • What is the role of translators in programming?
    Translate high-level languages into machine code
  • What are low-level languages?
    • Programming languages closely representing machine language
    • More difficult to understand than high-level languages
    • Execute quicker than high-level languages
  • What is machine code?
    Low-level language directly understood by the CPU
  • How is machine code represented?
    By binary numbers consisting of 0s and 1s
  • Why is machine code difficult to write and debug?
    It consists of thousands of 0s and 1s
  • What does assembly language use to represent instructions?
    Mnemonics that correspond to machine code
  • How does assembly language compare to high-level languages?
    It is easier to understand than machine code
  • What are the benefits of using mnemonics in assembly language?
    • Easier to understand and debug
    • Brief representations of actual commands
    • Quicker to write than binary
    • Easier to spot mistakes
  • What is the Little Man Computer (LMC)?
    A simulation of a basic processor
  • What architecture does the Little Man Computer use?
    Von Neumann architecture
  • What are opcodes in machine code and assembly instructions?
    Operation codes specifying executable instructions
  • What is an operand in programming?
    Data manipulated by the CPU according to opcode
  • What are the components of a program instruction in assembly language?
    • Opcode: Specifies the instruction
    • Operand: Data manipulated by the instruction
  • How are opcode and operand values represented?
    Both are ultimately represented in binary
  • Why is hexadecimal used in programming?
    It represents larger values in fewer characters
  • What is the hexadecimal representation of the decimal number 250?
    FA
  • What is the difference between denary and binary?
    • Denary: Base 10, digits 0-9
    • Binary: Base 2, digits 0 and 1
  • What is the significance of the stored program concept?
    • Programs stored in memory as instructions
    • Executed sequentially using ALU, control unit, and registers
  • What do high-level languages allow programmers to do?
    Write instructions in an easier language
  • What is the role of translators in programming?
    Translate high-level languages into machine code
  • What is source code?
    The code behind a computer program
  • Why must source code be translated?
    Computers cannot understand source code directly
  • What are the three types of translators?
    Interpreter, compiler, and assembler
  • What does a compiler do?
    Translates high-level languages into machine code
  • What is the process called when a compiler translates code?
    Compilation