[OT] range() for unix shell
Paul Jackson
pj at sgi.com
Thu Mar 7 19:34:43 EST 2002
The following patch fixes a couple of typos
in the above range() command:
--- range.py.orig Thu Mar 7 16:33:01 2002
+++ range.py Thu Mar 7 16:31:57 2002
@@ -13,7 +13,7 @@
In first case, low == 0 is implied
If no step size is given, 1 is assumed
"""
- exit
+ sys.exit(1)
low = 0
step = 1
@@ -27,6 +27,6 @@
high = int(sys.argv[2])
step = int(sys.argv[3])
else:
- usage
+ usage()
print string.join(map(str, range(low, high, step)))
--
--
I won't rest till it's the best ...
Programmer, Linux Scalability
Paul Jackson <pj at sgi.com> 1.650.933.1373
More information about the Python-list
mailing list