Skip to content

Commit bef4883

Browse files
Update old-style strings to f-strings (GH-30384)
Let me know if this sort of change is unwanted...
1 parent 5a2a650 commit bef4883

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

Doc/includes/minidom-example.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,10 @@ def handleSlide(slide):
4242
handlePoints(slide.getElementsByTagName("point"))
4343

4444
def handleSlideshowTitle(title):
45-
print("<title>%s</title>" % getText(title.childNodes))
45+
print(f"<title>{getText(title.childNodes)}</title>")
4646

4747
def handleSlideTitle(title):
48-
print("<h2>%s</h2>" % getText(title.childNodes))
48+
print(f"<h2>{getText(title.childNodes)}</h2>")
4949

5050
def handlePoints(points):
5151
print("<ul>")
@@ -54,11 +54,11 @@ def handlePoints(points):
5454
print("</ul>")
5555

5656
def handlePoint(point):
57-
print("<li>%s</li>" % getText(point.childNodes))
57+
print(f"<li>{getText(point.childNodes)}</li>")
5858

5959
def handleToc(slides):
6060
for slide in slides:
6161
title = slide.getElementsByTagName("title")[0]
62-
print("<p>%s</p>" % getText(title.childNodes))
62+
print(f"<p>{getText(title.childNodes)}</p>")
6363

6464
handleSlideshow(dom)

0 commit comments

Comments
 (0)