Compiler vs Interpreter — what actually happens when code runs?

Every programming language needs a way to run code. Yet the process is rarely visible. We write instructions. The machine executes them. Something happens in between. Two words appear again and again in explanations: compiler and interpreter. They look similar.…