#!/bin/bash clear echo -e "\n\n" echo -n " Enter string 1: " read -r string_1 echo -e "\n" echo -n " Enter string 2: " read -r string_2 echo -e "\n" echo -n " Enter string 3: " read -r string_3 if [ "$string_1" == "$string_2" ] && [ "$string_2" == "$string_3" ]; then echo -e "\n\n All strings match:\n" echo -e " String 1: ${string_1}\n" echo -e " String 2: ${string_2}\n" echo -e " String 3: ${string_3}\n\n" elif [ "$string_1" != "$string_2" ] && [ "$string_1" == "$string_3" ]; then echo -e "\n\n Two strings match:\n" echo -e " String 1: ${string_1}\n" echo -e " String 3: ${string_3}\n\n" elif [ "$string_1" == "$string_2" ] && [ "$string_1" != "$string_3" ]; then echo -e "\n\n Two strings match:\n" echo -e " String 1: ${string_1}\n" echo -e " String 2: ${string_2}\n\n" else echo -e "\n\n No strings match!\n\n" fi