Logo

Question preview

What the fork?

What this preview is

About this preview

What the fork? is a cooked quant interview question on operating systems.

Unlock full access to getcracked

Join to unlock this question, detailed solutions, and our complete library of quant finance interview prep.

What this operating-systems process-creation question tests

This is a foundational question about Unix/Linux process management, specifically the fork() system call. It targets whether candidates understand the mechanics of process creation and how the kernel communicates the outcome to a parent process.

The question probes both knowledge of the API contract and conceptual clarity: after fork() succeeds, execution continues in two separate processes, and the kernel must distinguish between them. Your answer should reflect how the return value differs between the parent and child contexts, and why the design makes sense for process tree construction and control flow.

  • Process identifiers (PIDs) and the process table
  • Parent–child process relationships
  • Control flow after system calls that create new processes
  • Error handling and return-value semantics in system-level APIs

Related learning resources

  • Operating Systems: Three Easy Pieces