[Solved] python string format without {}


I think this is more of a subjective question. I would argue that its ok following the principle of duck typing: If it looks like a duck, swims like a duck, and quacks like a duck, then it probably is a duck.

If you are looping through an array of strings and they all have the format() method, then just assume they all have something to be formated and format it.

solved python string format without {}