Print Triangle of Numbers using shell script in Linux/unix
Q. How do I write Shell Script to print triangle of Numbers
#!/bin/bash for((i=1;i<=5;i++)) do for((k=1;k<=(5-i);k++)) do echo -e " \c " done for((j=1;j<=i;j++)) do echo -e " $j \c" done echo -e "\n" done
If You Liked This Post Please Take a Time To Share This Post
This post was written by: Sandeep Kumar Singh
Iam Sandeep Kumar Singh from Delhi,India. I am technology lover who loves to keep updated with latest technology. I love to read and write about Linux in free time. Iam also interested in Web Technology.