Easy question, and I worked it out by trial and error but I’d like to understand the logic…

Why would I not put colons after every line in this definition?

def append_size(lst):

new_addition = len(lst)

lst.append(new_addition)

return lst

print(append_size([23, 42, 108]))

I.e. why would it not be -

def append_size(lst):

new_addition = len(lst):

lst.append(new_addition):

return lst

Thanks!