The UNIX and Linux Forums
>
Top Forums
>
Shell Programming and Scripting
the given code goes in infinite loop and does not increment variable i
.
User Name
Remember Me?
Password
google unix.com
Forums
Register
Forum Rules
Links
Albums
FAQ
Members List
Calendar
Search
Today's Posts
Mark Forums Read
Thread
:
the given code goes in infinite loop and does not increment variable i
View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
#
7
(
permalink
)
12-26-2007
summer_cherry
Registered User
Join Date: Jun 2007
Location: Beijing China
Posts: 1,092
wrong format
HI,
There are two typos for you i think.
First,
5 ]
not
5]
Second,
`
not
'
Code:
i=1; while [ $i -le
5 ]
do echo "welcome $i times" i=
`
expr $i + 1
`
done
summer_cherry
View Public Profile
Find all posts by summer_cherry
Find summer_cherry's past nominations received
Find summer_cherry's present nominations given