What is the best way to create a new empty list in Python?
l = []
or
l = list()
I am asking this because
Just to highlight @Darkonaut answer because I think it should be more visible.
new_list = [] or new_list = list() are both fine (ignoring performance), but append() returns None, as result you can't do new_list = new_list.append(something).
new_list = []
new_list = list()
append()
None
new_list = new_list.append(something)