Unix/Linux Go Back    


Homework & Coursework Questions Students must use and complete the template provided. If you don't, your post may be deleted! Special homework rules apply here.

Display number from 10 to 1 using shell programming in while loop

Homework & Coursework Questions


Tags
display 10 to 1 ushing shell programming

Closed    
 
Thread Tools Search this Thread Display Modes
    #1  
Old Unix and Linux 08-04-2015
aswin aswin is offline
Registered User
 
Join Date: Aug 2015
Last Activity: 4 August 2015, 1:44 PM EDT
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Display Display number from 10 to 1 using shell programming in while loop

echo "enter the number"
read n
while [ $n -ge 0 ]
do
echo "$n"
let n--
done

Last edited by aswin; 08-04-2015 at 11:39 AM.. Reason: show an error
Sponsored Links
    #2  
Old Unix and Linux 08-04-2015
Corona688 Corona688 is offline Forum Staff  
Mead Rotor
 
Join Date: Aug 2005
Last Activity: 21 July 2017, 2:59 PM EDT
Location: Saskatchewan
Posts: 22,291
Thanks: 1,110
Thanked 4,204 Times in 3,888 Posts
Read the special homework rules.
Sponsored Links
Closed

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Linux More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Display number from 10 to 1 using shell programming in while loop aswin Shell Programming and Scripting 2 08-04-2015 11:59 AM
for loop iteration and shell programming startup kashif_islam Shell Programming and Scripting 3 01-13-2012 09:33 AM
loop to display whatever number use types gangsta Shell Programming and Scripting 3 12-05-2011 09:25 AM
Kernel Programming: Finding the number of I/O requests Ir1s UNIX for Advanced & Expert Users 2 06-11-2009 11:10 AM
obtaining a line number in ksh programming wilsontan Shell Programming and Scripting 1 02-22-2006 02:30 AM



All times are GMT -4. The time now is 04:46 PM.