diff --git a/Script1.sh b/Script1.sh index 970b10cc..aebbc168 100644 --- a/Script1.sh +++ b/Script1.sh @@ -1,4 +1,7 @@ -#!/bin/bash +!/bin/bash #This is my 1st shell script to print output echo "Hello All, Welcome to AWS/Devops Class" echo "Hello, How are you?" +echo "Samiksha" +echo "Vikas" +echo "Welcome to Young Minds" diff --git a/Script12.sh b/Script12.sh index d75af12d..1bca0b03 100644 --- a/Script12.sh +++ b/Script12.sh @@ -1,24 +1,4 @@ #!/bin/bash -#this script is for if-elif-fi -echo "Please enter value of a" -read a -echo "Please enter vaule of b" -read b -if [ $a == $b ] -then - echo "a is equal to b" -elif [ $a -gt $b ] -then - echo "a is greater than b" -elif [ $a -lt $b ] -then - echo "a is less than b" -else - echo "None of the condition met" -fi -root@ip-172-31-42-137:~/scripts/shellscripts# ^C -root@ip-172-31-42-137:~/scripts/shellscripts# cat script12.sh -#!/bin/sh a="abc" b="efg" @@ -26,7 +6,7 @@ if [ $a = $b ] then echo "$a = $b : a is equal to b" else - echo "$a = $b: a is not equal to b" + echo "$a != $b: a is not equal to b" fi @@ -34,7 +14,7 @@ if [ $a != $b ] then echo "$a != $b : a is not equal to b" else - echo "$a != $b: a is equal to b" + echo "$a = $b: a is equal to b" fi diff --git a/Script13.sh b/Script13.sh index 958a0150..2a534ecf 100644 --- a/Script13.sh +++ b/Script13.sh @@ -9,7 +9,7 @@ if [ $a != $b ] then echo "$a != $b : a is not equal to b" else - echo "$a != $b: a is equal to b" + echo "$a = $b: a is equal to b" fi if [ $a -lt 100 -a $b -gt 15 ] diff --git a/Script2.sh b/Script2.sh index d507e753..07ff2a22 100644 --- a/Script2.sh +++ b/Script2.sh @@ -6,3 +6,5 @@ echo "Value of b" read b echo "Hello value of a is $a and value of b is $b" echo "This is sample change" +echo "bye" +echo "hi" \ No newline at end of file