the __new__(method is called before any object has been created (since object creation is what __new__(does)so it cannot have self object passed to it since one doesn' yet exist in fact__new__(is class method--these are similar to normal methods except that they are called on the class rather than on an instance and python supplies as their first argument the class they are called on the variable name cls for class is just conventionin the same way that self is the conventional name for the object itself so when we write fuzzybool( )under the hood python calls fuzzybool __new__(fuzzybool to create new object--sayfuzzy--and then calls fuzzy __init__(to do any further initializationand finally returns an object reference to the fuzzy object--it is this object reference that is set to most of __new__()' work is passed on to the base class implementationobject __new__()all we do is make sure that the value is in range class methods are set up by using the built-in classmethod(function used as decorator but as convenience we don' have to bother writing @classmethod before def __new__(because python already knows that this method is always class method we do need to use the decorator if we want to create other class methodsthoughas we will see in the final section now that we have seen class method we can clarify the different kinds of methods that python provides class methods have their first argument added by python and it is the method' classnormal methods have their first argument added by python and it is the instance the method was called onand static methods have no first argument added and all the kinds of methods get any arguments we pass to them (as their second and subsequent arguments in the case of class and normal methodsand as their first and subsequent arguments for static methodsdef __invert__(self)return fuzzybool( float(self)this method is used to provide support for the bitwise not operator (~just the same as before notice that instead of accessing private attribute that holds the fuzzybool' value we use self directly this is thanks to inheriting float which means that fuzzybool can be used wherever float is expected--providing none of the fuzzybool' "unimplementedmethods are usedof course def __and__(selfother)return fuzzybool(min(selfother)def __iand__(selfother)return fuzzybool(min(selfother)the logic for these is also the same as before (although the code is subtly different)and just like the __invert__(method we can use both self and other