Fork: Difference between revisions

Content deleted Content added
MaiconSoft (talk | contribs)
Added Delphi example
Updated to make the program able to compile and execute. Added output.
Line 1,020:
=={{header|Nim}}==
<lang nim>import posix
 
var pid = fork()
if pid < 0:
#echo error"Error forking a child"
elif pid > 0:
#echo "This is the parent, process and pidits ischild processhas id of", childpid, '.'
# Further parent stuff.
else:
#echo "This is the child process."
# furtherFurther Parentchild stuff here.</lang>
quit()
 
# further Parent stuff here</lang>
{{out}}
<pre>This is the parent process and its child has id 8506.
This is the child process.</pre>
 
=={{header|OCaml}}==