- Define a class that does nothing and name it
SomeClass
- Create an instance of the class you defined and assign it to the variable
c
- True or False? In case of
c.x = 1
,x
is a variable of value 1 - How to retrieve the value of
x
attribute from the previous question?
class SomeClass:
pass
c = SomeClass()
- False. in
c.x
,x
is an attribute of the instancec
and not a variable c.x