This project is a modular Python quiz application with a graphical interface. It is designed for formative assessment in the Intensive Foundations of Computer Science and Programming course.
What is this?
This is a simple quiz app. When you run it, a window will appear with questions and a text input field for answers. Type your answer and click the "Submit" button. At the end, your score will be shown.
How do I use it?
- Install dependencies if you do not already have them.
- Run the quiz app
- Answer the questions as they appear.
- At the end, see your score!
You need Python 3.x installed. Tkinter is usually included with Python. If you have Python, you likely have everything you need.
To install Python, visit: https://www.python.org/downloads/
- Download or clone this repository to your computer.
- Open a terminal (Command Prompt on Windows, Terminal on macOS/Linux) and navigate to the project folder. Note if the
l6-ifcs-formative-python-quizfolder is nested inside other folders, you will need to specify this in the path below before the repository folder and separate them by a/:cd l6-ifcs-formative-python-quiz - Run the following command:
python run_quiz.py
- The quiz window will appear. Answer the questions and see your score at the end.
quiz_logic.py: Contains theQuizclass for managing questions and scoring.quiz_questions.py: Stores the quiz questions and answers in a list.quiz_gui.py: Implements the Tkinter graphical interface (QuizAppclass).run_quiz.py: Launches the quiz application.
- To add or change questions, edit the
quiz_questionslist inquiz_questions.py. - All quiz logic is separated from the interface for easy maintenance and extension.
- You can further extend the app by adding new features or changing the interface in
quiz_gui.py.