Operating Systems: How One Processor Pretends to Be Many
The hidden manager inside every computer: processes, scheduling, locks, deadlocks, memory, file systems, devices, virtual machines and protection.
Operating Systems · 50 questions
Try 3 questions
1. What is the difference between a program and a process?
- A process is a program being run
- They are two names for one thing
- A process is a smaller program
Show the answer
Answer: A process is a program being run
A program is a file of instructions; a process is one running instance, with its own memory, registers and open files.
2. Unlike separate processes, threads within one process share what?
- Nothing at all with each other
- The same memory address space
- The same processor core, always
Show the answer
Answer: The same memory address space
Threads see the same variables and heap, which makes communication cheap but also makes race conditions possible.
3. On Unix-like systems, what does the fork() system call do?
- Ends the process and all its threads
- Creates a copy of the calling process
- Splits a file into two separate parts
Show the answer
Answer: Creates a copy of the calling process
fork() returns twice, once in the parent and once in the new child, which then often loads a different program.
The whole quiz comes before your apps
BrainTok asks a few questions like these before the apps you choose open, so your screen time turns into learning. For iPhone.
Join the beta