echo '((3+(2^3)) * 34^2 / 9)-75.89' | awk "BEGIN{ print $(cat) }"
Run Code Online (Sandbox Code Playgroud)
上述语法适用于计算结果“1337”。
echo '((3+(2^3)) * 34^2 / 9)-75.89' | awk "BEGIN{ print $* }"
Run Code Online (Sandbox Code Playgroud)
但是上面的语法不起作用,尽管没有错误。
请各位指教。