.... The console output uses memory mapping and maps a specific portion of the memory to the console. Thus writing to the console output is as simple as writing into a specific memory location. The CPU reads instructions from the memory and executes them. The memory contains our program code and can be used by the program to store data.