The UNIX School: 5 different ways of doing Arithmetic operations in UNIX

The UNIX School: 5 different ways of doing Arithmetic operations in UNIX

瀏覽:1275
日期:2025-04-25
$ let z=x+y $ echo $z 7 let can work with unary operators as shown below: $ let z=++z $ echo $z 8 5. The awk command used as shown below to do the arithmetic operations of shell variables. $ echo "" | awk '{print '$x' + '$y'}' 7 Enjoy Arithmetic!!! Note: ...看更多