Recently, I have been working with some bash scripts and browsing the manual pages. From what I have gathered, $(( ))mean exprand [ ]mean test?
For $(( )):
echo $(( 5 + 3 ))
has the same result as:
echo $(expr 5 + 3)
For [ ]:
test 'str' = 'str'
has the same meaning of success as:
[ 'str' = 'str' ]
Did I understand my opinion correctly?
source
share