Section 4: String Formatting

Doubts and Discussion Thread for Section 4: String Formatting!

coord={‘latitude’:‘37.24N’,‘longitude’:’-115.81W’}

‘coordinates:{latitude},{longitude}’.format(**coord)

What is the meaning of **coord in format function

@sharmajatinj3 So, ** is called Python Packing and Unpacking operator. We use two operators * (for tuples) and ** (for dictionaries). In this particular question, since we are using dictionaries, that’s why we have used double star operator to unpack the arguments.
To further understand this concept, you can take a look at this URL.