You are here : python_3Built-in Functionsdelattr

delattr() - Built-in Functions

This is a relative of setattr().  The arguments are an object and a
string.  The string must be the name of one of the object’s attributes.  The
function deletes the named attribute, provided the object allows it.  For
example, delattr(x, 'foobar') is equivalent to del x.foobar.


Syntax

delattr(object, name)


Example


Output / Return Value


Limitations


Alternatives / See Also


Reference