You are viewing a single comment's thread. Return to all comments →
Using case
#!/bin/bash # Commented out as 'cat -' will read the input #read X #read Y #read Z #case $(printf '%s\n%s\n%s\n' $X $Y $Z | sort | uniq | wc -l) in case $(cat - | sort | uniq | wc -l) in 3) echo "SCALENE" # rozno ramienny ;; 2) echo "ISOSCELES" # 2 ramienny ;; 1) echo "EQUILATERAL" # rownoboczny ;; esac
Seems like cookies are disabled on this browser, please enable them to open this website
More on Conditionals
You are viewing a single comment's thread. Return to all comments →
Using case