I have a list that I am appending different objects to.
How would I find the total number of instances of a specific class within that list please?
I have a list that I am appending different objects to.
How would I find the total number of instances of a specific class within that list please?
print(sum([1 for x in llist if isinstance(x, my_class)]))