56. What translates and executes source code into machine language one line at a time?

Answer: C

Explanation:

Interpreter translates and executes source code into machine language one line at a time.

An interpreter processes source code by translating it into machine language line by line during execution, allowing for immediate execution of code.

A) Assembler

An assembler translates assembly language into machine code, but it does so for an entire program at once rather than line by line during execution. Therefore, it does not fit the description of translating and executing source code incrementally.

B) Operating system

An operating system manages computer hardware and software resources and provides common services for computer programs. It does not translate or execute source code into machine language, making this option incorrect.

C) Interpreter

An interpreter directly translates and executes source code one line at a time, which aligns perfectly with the question's requirements. This allows for immediate feedback and debugging as the code is run.

D) Compiler

A compiler translates the entire source code into machine language before execution, which means it does not operate on a line-by-line basis. This makes it unsuitable as the answer to the question posed.

Conclusion

The interpreter is the only option that accurately describes the process of translating and executing source code line by line. All other options either serve different functions or operate in a manner that does not meet the criteria established in the question. Thus, the interpreter is definitively the correct answer.