Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- echo "Exam Print Pyramid"
- p=1
- echo -n "Enter Number :"
- read n
- for (( i=0;i<=$n;i++ ))
- do
- for (( k=$n;k>=$i;k-- ))
- do
- echo -n " "
- done
- for (( j=1;j<=i;j++ ))
- do
- echo -n " $p"
- p=`expr $p + 1`
- done
- echo " "
- done
Add Comment
Please, Sign In to add comment