The code below seems to work and outputs "8 is greater than 5". However, what unexpected result will tell you it is not functioning properly?
#!/bin/bash
var="8"
if [ $var > 5 ]; then
echo "$var is greater than 5"
fi
The code below seems to work and outputs "8 is greater than 5". However, what unexpected result will tell you it is not functioning properly?
#!/bin/bash
var="8"
if [ $var > 5 ]; then
echo "$var is greater than 5"
fi