short_list = [1, 2, '3', 4]
sum = 0
for i in short_list:
try:
sum += i
except Exception as e:
print("Invalid value")
print("Total sum:", sum)
with open('helloworld.csv', 'a') as f:
line = f.readline()
while line:
print(line)
line = f.readline()
df.loc[0]
df[0]
df.get(0)
df.columns()
> Index(['age', 'workclass', 'fnlwgt', 'education', 'education-num',
> 'marital-status', 'occupation', 'relationship', 'race', 'sex',
> 'capital-gain', 'capital-loss', 'hours-per-week', 'native-country',
> 'class'],
> dtype='object')
df.education-num.mean()
https://code.visualstudio.com/
Install Visual Studio Code to start with ICSS next week