RosettaCodeData/Task/Fork/Python/fork.py

8 lines
74 B
Python

import os
pid = os.fork()
if pid > 0:
# parent code
else:
# child code