the coordinate of the top left corner the width (in pixelsof the rectangle then height (in pixelsof the rectangle the second way is as pygame rect objectwhich we will call rect objects for short for examplethe code below creates rect object with top left corner at ( that is pixels wide and pixels tallimport pygame spamrect pygame rect( spamrect =( true the handy thing about this is that the rect object automatically calculates the coordinates for other features of the rectangle for exampleif you need to know the coordinate of the right edge of the pygame rect object we stored in the spamrect variableyou can just access the rect object' right attributespamrect right the pygame code for the rect object automatically calculated that if the left edge is at the coordinate and the rectangle is pixels widethen the right edge must be at the coordinate if you reassign the right attributeall the other attributes are automatically recalculatedspam right spam left here' list of all the attributes that pygame rect objects provide (in our examplethe variable where the rect object is stored in variable named myrect)