http://blog.csdn.net/jason314/article/details/5640969The fork () call will copy a new process that is almost identical to the current process (except for the fork's return value), each of which has its own space, each with its own local variables,
Transferred from: http://blog.csdn.net/jason314/article/details/5640969First, Fork Introduction knowledgeA process, including code, data, and resources assigned to the process. The fork () function creates a process that is almost identical to the
First, Fork Introduction knowledgeA process, including code, data, and resources assigned to the process. The fork () function creates a process that is almost identical to the original process through a system call.That is, two processes can do
I. Usage Analysis:Fork () This function, it can be said that the name of the person, it is well known that fork the word is meant to fork, the foreigner to take the academic name when there will always be some pictographic ideas, so there is ~The
definition
Binary tree is a finite set of n (n>=0) nodes, which is an empty set called an empty binary tree, or has a root node and two separate left child trees and right child trees, called root nodes, which are disjoint.
two
(1) Fork system call DescriptionThe fork system call is used to create a new process from an existing process called a child process, and the original process is called the parent process. The fork is called once, returned two times, and the two
Basic ConceptsThe level of the node is defined from the root and the root is the first layer and the child of the root is the second layer.Height of the binary tree: the maximum level of the node in the tree is called the depth (Depth) or height of
Fork is one of the most difficult concepts to understand: it executes once but returns two values.First, let's look at the prototype of the fork function:# include # include pid_t fork (void);return value:Negative number: If there is an error, fork (
ConceptThe level of the node is defined from the root and the root is the first layer and the child of the root is the second layer.Height of the binary tree: the maximum level of the node in the tree is called the depth (Depth) or height of the
Binary tree is a very common and useful data structure, which combines the advantages of an ordered array with a linked list. Finding data in a binary tree is as fast as finding data in an array, and adding and removing data in a binary tree is as
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.