Guest User

Untitled

a guest
Jul 21st, 2018
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.23 KB | None | 0 0
  1. #include <stdlib.h>
  2. #include <sys/types.h>
  3. #include <unistd.h>
  4.  
  5. int main()
  6. {
  7. int pid;
  8. pid=fork();
  9. if(pid>0)//child
  10. {
  11. sleep(1000);
  12. }
  13. else//parent
  14. {
  15. exit(0);
  16. }
  17. }
Add Comment
Please, Sign In to add comment