shell script, the function of the internal variables may be defined as the local and global variables, local variables define local, global variables with no local, global variables can be visible outside the function, as follows:
#!/bin/bash function callee(){ name="cnblogs" } function caller(){ callee echo $name } caller echo $name