First on a map:
code show as below:
#!/bin/bash echo "hello world" echo `ls +`
Results are as follows:
PS:
1. If you want to redirect data to a file at the same time and stdout, you can use the tee command.
2. -: used to redirect stdout or stdin
echo "hello world" | cat -
References:
Shell input / output redirection
Reproduced in: https: //www.cnblogs.com/gattaca/p/7223153.html