fork download
  1. #!/usr/bin/env python
  2.  
  3. import csv
  4.  
  5. f = open('name.csv', 'r', encoding="utf-8")
  6. reader = csv.reader(f)
  7. header = next(reader)
  8.  
  9. for row in reader:
  10. if row[27][2] == u"山下":
  11. print(row[27])
  12.  
  13. f.close()
  14.  
Runtime error #stdin #stdout #stderr 0.03s 44632KB
stdin
Standard input is empty
stdout
Standard output is empty
stderr
Traceback (most recent call last):
  File "<builtin>/app_main.py", line 75, in run_toplevel
  File "prog.py", line 5, in <module>
    f = open('name.csv', 'r', encoding="utf-8")
TypeError: __init__() got an unexpected keyword argument 'encoding'