okso much for the design phase--let' move on to implementation our first task is to start coding the main classperson in your favorite text editoropen new file for the code we'll be writing it' fairly strong convention in python to begin module names with lowercase letter and class names with an uppercase letterlike the name of self arguments in methodsthis is not required by the languagebut it' so common that deviating might be confusing to people who later read your code to conformwe'll call our new module file person py and our class within it personlike thisfile person py (startclass personstart class all our work will be done in this file until later in this we can code any number of functions and classes in single module file in pythonand this one' person py name might not make much sense if we add unrelated components to it later for nowwe'll assume everything in it will be person-related it probably should be anyhow--as we've learnedmodules tend to work best when they have singlecohesive purpose coding constructors nowthe first thing we want to do with our person class is record basic information about people--to fill out record fieldsif you will of coursethese are known as instance object attributes in python-speakand they generally are created by assignment to self attributes in class' method functions the normal way to give instance attributes their first values is to assign them to self in the __init__ constructor methodwhich contains code run automatically by python each time an instance is created let' add one to our classadd record field initialization class persondef __init__(selfnamejobpay)self name name self job job self pay pay constructor takes three arguments fill out fields when created self is the new instance object this is very common coding patternwe pass in the data to be attached to an instance as arguments to the constructor method and assign them to self to retain them permanently in oo termsself is the newly created instance objectand namejoband pay become state information--descriptive data saved on an object for later use although other techniques (such as enclosing scope reference closurescan save detailstooinstance attributes make this very explicit and easy to understand notice that the argument names appear twice here this code might even seem bit redundant at firstbut it' not the job argumentfor exampleis local variable in the scope of the __init__ functionbut self job is an attribute of the instance that' the more realistic example