echo 'Enter the marks of student in five subjects '
read a
read b
read c
read d
read e
total=` expr $a + $b + $c + $d + $e `
per=` expr $total / 5 `
echo "He got $total in subtotal marks and $per% marks in five subjects. So his/her division is "
if test $per -ge 60
then
echo "FIRST"
elif test $per -ge 40
then
echo "SECOND"
elif test $per -ge 33
then
echo "THIRD"
else
echo "Fail"
fi
No comments:
Post a Comment