Monday, 27 May 2013

Shell Script for area of triangle

echo "Enter the length and Breadth of rectangle:"
read n1
read n2
area=$(($n1*$n2))
echo "Area of rectangle is "$area
echo -n "Enter radius of the Circle:- "
read r
echo -n "Area of Circle is "
carea= echo "3.14 * $r * $r" | bc
echo $carea


1 comment: