Question 25
What will be the output of code snippet given below.
1 from jinja2 import Template 2 3 output1 = Template("Company name of car model {{ c.getModel() }} is {{ c.getCompany() }}") 4 output2 = Template("Company name of car model {{ c.model() }} is {{ c.getCompany() }}") 5 output3 = Template("Company name of car model {{ c.getModel() }} is {{ c.company() }}") 6 7 class Car: 8 def __init__(self, company, model): 9 self.company = company10 self.model = model1112 def getCompany(self):13 return self.company1415 def getModel(self):16 return self.model1718 c1 = Car("Maruti","ERTIGA")19 c2 = Car("Honda","AMAZE")20 c3 = Car("Tata","NEXON")2122 print(output1.render(c = c1))23 print(output1.render(c = c2))24 print(output1.render(c = c3))