๐ก Activity Solution
๐ก Activity Solution
1๏ธโฃ Compiler:
- A program that translates the entire source code into object code (machine code) before execution.
It checks for errors during the build stage; if none exist, it produces an .exe file through linking.
2๏ธโฃ Interpreter:
- A program that reads and executes source code line-by-line.
If it finds an error, it stops immediately and shows an error message.
It does not create or save any .exe file.
3๏ธโฃ Assembler:
- A translator that converts assembly language instructions into machine language (binary).
4๏ธโฃ Linker:
- A tool that combines object code and required libraries to produce an executable (.exe) file.
5๏ธโฃ .exe file:
- A file containing machine code instructions ready to be loaded and executed by the CPU.
6๏ธโฃ Loader:
- A system program that loads the executable (.exe) into main memory (RAM) so the CPU can run it.
7๏ธโฃ Which is faster:
- Compiled languages are faster because their code is translated to machine code in advance, not during execution.
8๏ธโฃ Does Interpreter produce .exe?
- โ No, an interpreter does not generate or store an .exe file.
9๏ธโฃ Does Interpreter save machine code?
- โ No, it executes directly in memory without saving machine code on disk.
๐ Does Compiler produce .exe?
- โ Yes, after translation and linking, a compiler produces an .exe file stored on disk.
1๏ธโฃ1๏ธโฃ Does Compiler save machine code?
- โ Yes, it saves machine code as part of the executable file for later use.
0 comments