Prepare for the A Level Computer Science OCR Exam with engaging quizzes, detailed explanations, and effective study tips. Maximize your readiness and boost your confidence for exam day!

Practice this question and more.


In LMC, what is the purpose of the "BRA" instruction?

  1. Branches to the next instruction unconditionally

  2. Loads data into the accumulator

  3. Stores the accumulator’s value

  4. Halts processor execution

The correct answer is: Branches to the next instruction unconditionally

The "BRA" instruction in the Little Man Computer (LMC) architecture is used for unconditional branching, which means it directs the program to jump to a specified instruction in the program without any conditions. This is fundamental in controlling the flow of a program, enabling it to repeat sections or skip over certain parts based on the program’s logic. When "BRA" is executed, the program counter (PC) is updated to the address specified by the instruction, effectively allowing the program to 'branch' to that point and continue execution from there. This is critical for implementing loops and jump statements, which form a crucial part of many algorithms. Unconditional branching differs from conditional branches (if they were to be considered), which execute jumps based only on specific criteria or conditions. The other options include functions like loading data, storing values, and halting execution, which serve different purposes within the architecture but do not pertain to the branching behavior of the program's flow control as defined by the "BRA" instruction.