the prototype pattern self unit_type "archerself life life self speed speed self attack_power attack_power self attack_range attack_range self weapon weapon def __str__(self)return "type{ }\ "life{ }\ "speed{ }\ "attack power{ }\ "attack range{ }\ "weapon{ }formatself unit_typeself lifeself speedself attack_powerself attack_rangeself weapon class barracks(object)def generate_knight(self)return knight( "short sword"def generate_archer(self)return archer( "short bow"if __name__ ="__main__"barracks barracks(knight barracks generate_knight(archer barracks generate_archer(print("[knight {}format(knight )print("[archer {}format(archer )nextyou will see the result of running this program we now have knight and an archereach with its very own unique values for the unit attributes read through the code and try to understand what each line is doing before you continue to the explanation of the results