We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Prepare
- Linux Shell
- Bash
- More on Conditionals
- Discussions
More on Conditionals
More on Conditionals
Sort by
recency
|
350 Discussions
|
Please Login in order to post a comment
read X Y Z
X=((Y)) Z=$((Z))
if [[ Y && X ]]; then echo "EQUILATERAL" elif [[ Y || Z || X ]]; then echo "ISOSCELES" else echo "SCALENE" fi
Output: I am getting ISOSCELES as output What is the issue with this code?
is there a way to read X Y and Z in one read command?
read x read y read z if [[ y && z ]]; then echo "EQUILATERAL" elif [[ y || z || z ]]; then echo "ISOSCELES" else echo "SCALENE" fi