hi, if any one give me a code for this output if i give input 4 means i want this output * * * * * * * * * * actually i am not familier with for loop in shell script . so that i ask this help to u send your answer as soon as possible thanks
I implemented this just for fun. But this sounds so much like a homework assignment that I'm only posting a few lines (the looping part) of my solution. Code: #!/bin/sh ... while [ $n -gt 0 ]; do ... n=$[n-1] done Don't forget to make the file executable with 'chmod +x scriptfile'.