(Jan-09-2022, 12:05 PM)MaartenRo Wrote: It restarts the shell. How can i get the script to make the multiple choice tests?What do you mean? Your script generates files capitalsquiz1.txt through capitalsquiz35.txt and capitalsquiz_answers1.txt through capitalsquiz_answers35.txt. Did you want the program to ask you the questions? Well then you will have to add things. Use print(), input() and if.
And also: Larz60+ was right: you should not use the old-fashoned way to format strings. You had better use f-strings. They are much easyer to understand.