listing help features are visible again addintdecoratorfunctool py from funcnamedecoratorfunctool import funcnamedecoratorfunctool @funcnamedecoratorfunctool def addintdecorator( :int* :int-int'''add two variables (xy)xintegerpostional argument yintegerkeyword argument returntypeinteger ''return ( + intadd=addintdecorator( = function nameaddintdecorator print("intadd ="intadd help(addintdecoratorlines - will be displaed print(addintdecorator __annotations__##{'return'' '' '@property in this sectionarea and perimeter of the rectangle is calculated and '@propertyis used to validate the inputs before calculation furtherthis example is extended in the next sections for adding more functionality for 'attribute validationexplanation listing in line of the listing@property is used for 'lengthattribute of the class rectangle since@property is usedtherefore 'getterand 'settercan be used to validate the type of length note thatin setter parti lines - self _length (see '_before lengthis used for setting the valid value in 'lengthattribute in the setter part validation is performed at line using 'isinstancen line the value of length is passed as floattherefore error will be raised as shown in line nowwhenever 'lengthis accessed by the codeit' value will be return by getter method as shown in lines - in the other wordsthis block will be executed every time we use 'lengthvalue to demonstrate thisprint statement is used in line for exampleline print the length valuetherefore line printed first and then length is printed as shown in lines - also@property is used for the method 'areaas well thereforeoutput of this method can be directly obtained as shown in lines - furtherfor calculating areathe 'lengthvariable is required therefore line will be printed as outputwhich is explained in previous paragraph notein this listingthe type-check applied to 'lengthusing @property butthe problem with this method is that we need to write it for each attribute length and width in this case which is not the efficient way to do the validation we will remove this problem using descriptor in next section listing attribute validation using @property rectproperty py class rectangle''-calculate area and perimeter of rectangle -getter and setter are used to displaying and setting the length value -width is set by init function '' (continues on next page generalized attribute validation