Notation for errors I met.
For quick search
Build in function
A
assert
code:assert statement
explanation:
R
readline()
read the first line and begin with second line
data:
code:
header
:['Title', 'Released', 'Label', 'UK Chart Position', 'US Chart Position', 'BPI Certification', 'RIAA Certification\n']
line
:Please Please Me,22 March 1963,Parlophone(UK),1,-,Gold,Platinum
S
strip()
can be used to delete the \n
code
code:
output:
Imported modules
csv
csv.DictReader()
read csv
file,
default denote the first row as the field labels,line
is dict
data type
code:
more details can be found in ud032 Using CSV Module
xlrd
xlrd.open_workbook()
read xls
file
code:
details can be found in ud032 Notebook
ZipFile
code: