ssssshhocking

Untitled

Mar 21st, 2023 (edited)
214
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.29 KB | None | 0 0
  1. def makeStupidTable(n):
  2. # Create the table head and body strings
  3. table_head = "<thead><tr><th>Number</th></tr></thead>"
  4. table_body = "<tbody>" + "".join([f"<tr><td>{i}</td></tr>" for i in range(n)]) + "</tbody>"
  5. table = f"<table>{table_head}{table_body}</table>"
  6. return table
Advertisement
Add Comment
Please, Sign In to add comment