LearnFrenzy
Sign in Take a free test

Python · Guided project

Build a Placement Quiz Game — Guided Project

A timed multiple-choice quiz that loads questions from a file, shuffles them and shows a final score with the questions you got wrong.

  • Beginner
  • ~3 hours
  • 5 steps

The brief

Build a small quiz game for aptitude or technical questions. Questions live in a CSV file, so anyone can add more without touching the code. The program shuffles them, asks one at a time, tracks the score and shows the correct answers for mistakes at the end.

Skills you will use: Lists · Loops · random module · CSV files

Build it

Step by step

Tick each step as you finish it. 0 of 5 done.

  1. Step 1Create the question file

    Make questions.csv with columns: question, a, b, c, d, answer. Add at least 10 questions.

  2. Step 2Load and shuffle

    Read the file into a list of dictionaries and shuffle it with random.shuffle().

  3. Step 3Ask and score

    Loop through the questions, accept only a/b/c/d, and keep a score and a list of wrong answers.

  4. Step 4Show the result

    Print the score, percentage and each wrong question with its correct answer.

  5. Step 5Stretch goal

    Add a 30-second timer per question using the time module, or let the user choose the number of questions.

Self-review before you call it done

Tick each point once your project really meets it. These are the things an interviewer will look for.

0 / 4 checked

Check all 4 points, then mark the project as finished.

Next

More guided projects

Search LearnFrenzy

Esc

Quick links