Skip to content
RED SAG Skills
hardStudy question · answer published in Python interview questions, so no pointspythonpython-basics

A list default in a dataclass

What happens when Python reaches this class definition?

from dataclasses import dataclass

@dataclass
class Cart:
    items: list = []
Choose one answer

Discussion 0

Join free to post in the discussion.

Related questions