mirror of
https://github.com/techarkit/shell-scripting-tutorial.git
synced 2025-08-03 07:34:30 +00:00
Create Logical operators
Logical Operators/Boolean Operators.
This commit is contained in:
21
Logical operators
Normal file
21
Logical operators
Normal file
@ -0,0 +1,21 @@
|
||||
#!/bin/bash
|
||||
#Purpose: Logical Operators/Boolean Operators. Student Marks Validation.
|
||||
#Version:1.0
|
||||
#Created Date: Sat May 12 21:21:03 IST 2018
|
||||
#Modified Date:
|
||||
#Author: Ankam Ravi Kumar
|
||||
# START #
|
||||
echo -e "Enter Your Maths Subject Marks: \c"
|
||||
read -r m
|
||||
echo -e "Enter Your Physics Subject Marks: \c"
|
||||
read -r p
|
||||
echo -e "Enter Your Chemistry Subject Marks: \c"
|
||||
read -r c
|
||||
|
||||
if test $m -ge 35 -a $p -ge 35 -a $c -ge 35
|
||||
then
|
||||
echo "Congratulations, You have passed in all subjects"
|
||||
else
|
||||
echo "Sorry You not upto mark in one of the subject"
|
||||
fi
|
||||
# END #
|
Reference in New Issue
Block a user