=1 >/dev/null 2>&1 &
Why write in/dev/null here, I measured the next, input a.txt have something, but input to/dev/null view nothing AH
Reply content:
=1 >/dev/null 2>&1 &
Why write in/dev/null here, I measured the next, input a.txt have something, but input to/dev/null view nothing AH
/dev/null is a black hole, there is no in-out.
Primarily used to discard output information.
This is output redirection, does not display standard output (STDOUT) and error messages (STDERR)
/dev/null is a black hole, and nothing will be lost when thrown in.
So make good use of/dev/null.
You understand that Dev/null is a junkyard, or a black hole, and nothing goes in. Position some unused output here and disappear ...
/dev/null is a special character device under Linux, which is mainly used to discard the output information, thus filtering out the error message, which helps to quickly find out the cause of the error.
This is the effect, when processing errors, the output from stderr is discarded into the file/dev/null. /dev/null is a special device file, and any data it receives will be discarded. A null device is also often called a black hole, because any data coming here will be gone.
Output redirection
You can refer to this article http://c.biancheng.net/cpp/view/2738.html