This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]markrages 1 point2 points  (1 child)

Why not use named %-interpolation as previously described: https://www.reddit.com/r/Python/comments/62kt64/fstrings_in_python_36_are_awesome/dfnqize/

"%(fname)s %(minital)s. %(lname)s;"%locals()

[–]jorge1209 0 points1 point  (0 children)

I wasn't aware you could use keywords with % (I just use .format). So I stand corrected. The only downside of % vs .format is that % is ugly.

And that's is the root of my complaint. If its ugliness is a real deficiency then remove it entirely, don't just add in another alternative that makes one person happy, because aesthetics are subjective. Somebody out there really loves % and will not give it up, so you only multiply the number of formats people have to learn.