Hi friends
How can I use "for loop" for decimal numbers?
ex: 0.1 < x < 0.6
I used this commands but does'nt work.
LIMIT=0.6
for ((x=0.1; x<=LIMIT; x++))
do
-
-
-
done
Many thanks
You want to do this in what? KSH? Bash? Perl?
Why don't you set a separate iterator variable like this:
// pseudo code - depends on your language
x=0.1
LIMIT = 6
for ((idx=x*10; idx<=LIMIT; idx++))
do
-
-
-
done