0
def display_scores(scores):
   list1 = [1]
   for items in list1:
      print("NAME   SCORE")
      print(*scores, sep = "\n")

Here's an example of an argument that could be used (["BOB", 1200, "ZAK", 8000, "ROB", 3000]) So the main thing I haven't figured out yet is how to separate the str(names) from the int(scores) in the list and to print it out underneath their respective columns so like the output for this one would look like

NAME   SCORE
BOB    1200
ZAK    8000
ROB    3000

But any kind of list in this format could be used as an argument. like ["ZOE", 500, "TOM" 1800]

ice
  • 1

0 Answers0