2012-05-10 | Paul Boddie | file changeset files shortlog | Changed the builtins module loading to use the module search path. This makes it easier to run the test program from another location. Added a note about relative imports. |
paul@343 | 1 | #!/usr/bin/env python |
paul@343 | 2 | |
paul@343 | 3 | x = [1, 2, 3] |
paul@343 | 4 | |
paul@343 | 5 | if x: |
paul@343 | 6 | y = len(x) |
paul@343 | 7 | else: |
paul@343 | 8 | def len(arg): |
paul@343 | 9 | return 0 |
paul@343 | 10 | |
paul@362 | 11 | z = len(x) |
paul@362 | 12 | |
paul@343 | 13 | # vim: tabstop=4 expandtab shiftwidth=4 |