Changeset 32554 in project


Ignore:
Timestamp:
07/06/15 15:30:13 (5 years ago)
Author:
svnwiki
Message:

Anonymous wiki edit for IP [127.0.0.1]: Renewing

File:
1 edited

Legend:

Unmodified
Added
Removed
  • wiki/chicken-for-python-programmers

    r31126 r32554  
    6464</enscript>
    6565
     66
     67<enscript highlight=python>
     68a = sum(["1", "2"], start="")
     69</enscript>
     70
    6671==== CHICKEN
    6772<enscript highlight=scheme>
     
    95100==== Python
    96101<enscript highlight=python>
    97 open("my-file.txt").read()
    98 </enscript>
     102open("my-file.txt").read() # Deprecated
     103</enscript>
     104
     105<enscript highlight=python>
     106with open("my-file.txt") as f:
     107    f.read()
     108</enscript>
     109
    99110
    100111==== CHICKEN
     
    109120<enscript highlight=python>
    110121open("my-file.txt").readlines()
     122</enscript>
     123
     124<enscript highlight=python>
     125with open("my-file.txt") as f:
     126    f.readlines()
    111127</enscript>
    112128
Note: See TracChangeset for help on using the changeset viewer.