Sum / Average an attribute of a list of objects December 30, 2022 by Tarik Use a generator expression: sum(c.a for c in c_list)