I am trying to work out how to complete a task that asks the following:
Create a string and use a method to generate a description of the new car as shown below. Print it – it should be formatted like the text below (including the line breaks).
Yesterday I bought a [Make] [Model].
It’s not “too” old. It was made in [year] …
I like it, though. It’s [colour], and it has [doors] doors!
The variables (make, model, year, colour and doors) need to be populated from a dictionary.
I have programmed the dictionary to look like this:
Car = {
'Make': 'Mitsubishi',
'Model': 'Lancer',
'Year': '2002',
'Colour': 'Green',
'Doors': '4',
}
How can i fill the variables in that string of text by referencing the dictionary 'Car'?
Thank you!