/Quizzer

SEN4a-AT1

Primary LanguagePythonThe UnlicenseUnlicense

Welcome to Quizzer!

Quizzer - a simple system that allows you to mix different questions from multiple question sets! Why? Because real world exams often test different topics at one time, but current pre-test/quiz systems often only tackle one topic at a time.

Getting started. 🚀

  1. Download the project folder.
  2. Extract the entire folder.
  3. Open VS-Code.
  4. In VS-Code, hold CTRL and hit K+O
  5. Open the project folder. Don't open Quizzer-main or any previous folders!
  6. The project should now be opened in VS-Code.
  7. Run 'Quizzer.py' in VS-Code.

System requirements.

  • VS Code or other IDE with ANSI Escape Sequences enabled.
  • Python 3.12 or higher.
  • Windows 10 (v22H2+) or 11.

Creating your own question sets.

Question sets 📝

This is an example question set: Addition.txt

{'Subject':'Maths','Topic':'Addition'}
{'Question':'What is 2 + 3', 'Answers':['10','5','22', '12'], 'SelectedAnswer':None, 'CorrectAnswer':2}
{'Question': 'What is 1 + 2', 'Answers': ['3', '5', '7', '1'], 'SelectedAnswer': None, 'CorrectAnswer': 0}

Simply put this file into any folder in the Subjects folder.

How does it work?

  • Each row of a question set is a dictionary.
  • The first row of the your question set always shows the subject and the topic.
{
  'Subject':'Maths',
  'Topic':'Addition'
}
  • Every other row represents a question, like so:
{
  'Question':'What is 2 + 3',        # Given question.
  'Answers':['10','5','22', '12'],   # List of possible answers.
  'SelectedAnswer':None,             # Always should be set to None.
  'CorrectAnswer':2                  # Index of the correct answer.
}

File system 📁

Inside the Subjects folder, you can create your own folder, and place your question sets inside :D

Every subject is stored in the Subjects folder. In each subject, a .txt file holds a question set.

Subjects/
├─ Math/
│  ├─ Addition.txt
│  ├─ Multiplication.txt/
├─ English/
│  ├─ Spelling.txt/

When setting up a test, the subjects and topics will be shown through the filename, for example: image 3