summaryrefslogtreecommitdiffstats
path: root/Demo
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2009-10-10 22:03:43 (GMT)
committerGeorg Brandl <georg@python.org>2009-10-10 22:03:43 (GMT)
commitffc87d5c8c26368cd6b01b4fb82e31f1e131551c (patch)
treebc76816e195855a1be542e4173fdbeb393c441d4 /Demo
parenta0bcc27e65e2cc0fd515ae91d88bfa74a0dd4a83 (diff)
downloadcpython-ffc87d5c8c26368cd6b01b4fb82e31f1e131551c.zip
cpython-ffc87d5c8c26368cd6b01b4fb82e31f1e131551c.tar.gz
cpython-ffc87d5c8c26368cd6b01b4fb82e31f1e131551c.tar.bz2
Style fixes.
Diffstat (limited to 'Demo')
-rw-r--r--Demo/scripts/find-uname.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/Demo/scripts/find-uname.py b/Demo/scripts/find-uname.py
index b76b9f0..958f8a4 100644
--- a/Demo/scripts/find-uname.py
+++ b/Demo/scripts/find-uname.py
@@ -21,20 +21,20 @@ import sys
import re
def main(args):
- unicode_names= []
+ unicode_names = []
for ix in range(sys.maxunicode+1):
try:
- unicode_names.append( (ix, unicodedata.name(unichr(ix))) )
+ unicode_names.append((ix, unicodedata.name(unichr(ix))))
except ValueError: # no name for the character
pass
for arg in args:
pat = re.compile(arg, re.I)
- matches = [(x,y) for (x,y) in unicode_names
- if pat.search(y) is not None]
+ matches = [(y,x) for (x,y) in unicode_names
+ if pat.search(y) is not None]
if matches:
print "***", arg, "matches", "***"
- for (x,y) in matches:
- print "%s (%d)" % (y,x)
+ for match in matches:
+ print "%s (%d)" % match
if __name__ == "__main__":
main(sys.argv[1:])