[Swift-user] iterate doesn't stop
Luciano Piccoli
piccoli at fnal.gov
Wed Mar 26 14:15:38 CDT 2008
Hi,
The following simple Swift script works fine:
-- iterate.swift -------
int N=4;
iterate i {
print (i);
} until (i == N);
---------------------
bash-3.00$ swift iterate.swift
Swift vsvn swift-r1744 cog-r1936
RunID: 20080326-1408-b4l23enc
Progress:
0
1
2
3
4
Final status:
However, if the number of iterations N is read from the command line it
does not stop:
-- iterate.swift -------
int N=@arg("N");
iterate i {
print (i);
} until (i == N);
----------------------
bash-3.00$ swift iterate.swift -N=4
Swift vsvn swift-r1744 cog-r1936
RunID: 20080326-1409-bv0q7jm2
Progress: 0
1
2
3
4
5
...
69348
69349
...
Any ideas why?
Thanks,
Luciano
More information about the Swift-user
mailing list