Three, Bash variables

1, user-defined variables

  1.1 What is a variable

    

 

  2.2 Variable setting rules

    

   

 

     

 

    2.3 Classification of variables

    

 

      

     2.4 Local variables (user-defined variables)

    

     

 

 

2, Environment Variables

  2.1 What is the environment variable

   

 

   2.2 Set Environment Variables

   

 

   3.3 System environment variables common

    

 

     

 

    Case:

      

 

3, the position of the variable parameter

      3.1 Location parameter variables

      

 

      Case 1: Addition Calculator

      

 

      The difference between $ *, $ @ $ # of: Case 2

      

 

      Case 3: $ * and $ @ the difference

      

 

 

4, predefined variables

    4.1 predefined variables

    

 

     

    The difference between $$ and $: Case 1!

    

    

 

    4.2 accept keyboard input

     

 

       Case:

      

 

 

      

 

      

Guess you like

Origin www.cnblogs.com/healy/p/11531985.html