python programming method defintion __add__(self,yoperator + __contains__(self,y__eq__(self,y__ge__(self,y__getitem__(self,y__gt__(self,y__hash__(self__int__(self__iter__(self__le__(self,y__len__(self__lt__(self,y__mod__(self,y__mul__(self,y__ne__(self,y__neg__(self__repr__(selfy in = > [yx> hash(xint(xfor in < len(xx< % * ! - repr(x__setitem__(self, ,y__str__(selfx[iy str(x__sub__(self,yx- description the addition of two objects the type of determines which add operator is called when is collection you can test to see if is in it returns true or false depending on the values of and returns true or false depending on the values of and returns the item at the yth position in returns true or false depending on the values of and returns an integral value for returns an integer representation of returns an iterator object for the sequence returns true or false depending on the values of and returns the size of where has some length attribute returns true or false depending on the values of and returns the value of modulo this is the remainder of / returns the product of and returns true or false depending on the values of and returns the unary negation of returns string version of suitable to be evaluated by the eval function sets the item at the ith position in to return string representation of suitable for user-level interaction the difference of two objects fig python operator magic methods convenience for each operator the magic method is givenhow to call the operator is givenand short description of it as well in the tableself and refer to the same object the type of determines which operator method is called in each case in the table the repr(xand the str(xoperators deserve little more explanation both operators return string representation of the difference is that the str operator should return string that is suitable for human interaction while the repr operator is called when string representation is needed that can be evaluated for instanceif we wanted to define these two operators on the dog classthe repr method would return the string "dog('mesa' , , 'wooof')while the str operator might return just the dog' name the repr operatorwhen calledwill treat the string as an expression that could later be evaluated by the eval function in python whereas the str operator simply returns string for an object importing modules in pythonprograms can be broken up into modules typicallywhen you write program in python you are going to use code that someone else wrote code that others wrote is usually provided in module to use moduleyou import it there are two ways to import module for the drawing program we are developing in this we want to use turtle graphics turtle graphics was first developed long time ago for programming language called logo logo was created around so the basis for turtle graphics is pretty ancient in terms of computer science it still this copy belongs to 'acha