0
Python List Functions
items = [2, 4, 6, 8, 10, 12, 14] num = len(items) \\ 2 print(num) It says that there's an unexpected character in the third line. Can anyone explain?
2 odpowiedzi
+ 6
Ayesha Tajalli ,
it should be:
num = len(items) // 2 # this an integer division that returns a whole number
+ 1
Ah I understand! Thank you<3