view represents the html fileswhich interact with the end user it represents the model' data to user controller it acts as an intermediary between view and model it listens to the events triggered by view and queries model for the same python code let us consider basic object called "personand create an mvc design pattern model py import json class person(object)def __init__(selffirst_name nonelast_name none)self first_name first_name self last_name last_name #returns person nameexjohn doe def name(self)return ("% % (self first_name,self last_name)@classmethod #returns all people inside db txt as list of person objects def getall(self)database open('db txt'' 'result [json_list json loads(database read()for item in json_listitem json loads(itemperson person(item['first_name']item['last_name']result append(personreturn result it calls for methodwhich fetches all the records of the person table in database the records are presented in json format