Is it possible to have truly random questions per quiz attempt?

Created on 27 November 2023, 7 months ago
Updated 28 November 2023, 7 months ago

Problem/Motivation

I'm trying to build a quiz that has ~12 questions and populates those questions by taking at random questions from specific categories.

For example:
Q1: A random question from the Sport category
Q2: A random question from the Animal category
Q3: A random question from the Movie category
etc.

For this, I've created each category as a vocabulary, a number of questions for each category and created a Quiz. Under "Randomization" I select "Categorized random questions" and choose how ever many questions I want and their category. This achieves what I'm after for the first attempt at the Quiz, however, it saves the questions, so every time the quiz is taken it is the same questions in the same order.

What I would like is that every time the test is taken, each question is randomised.

For example:
First attempt
Q1: Sport question number 2
Q2: Animal question number 1
Q3: Movie question number 10

Second attempt
Q1: Sport question number 4
Q2: Animal question number 2
Q3: Movie question number 3

Is this possible with the Quiz module? I'm not sure how it works but if it is not possible to dynamically create the questions, another solution could be to have some kind of template so that I can easily copy and save a new Quiz with the same parameters so I don't have to build a new Quiz completely every time.

Thanks for any help in this matter.

đź’¬ Support request
Status

Active

Version

6.0

Component

Code - Quiz core

Created by

🇳🇿New Zealand dominictaylor

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @dominictaylor
  • 🇳🇿New Zealand dominictaylor
  • 🇺🇸United States djdevin

    That's actually how it should work. Are you sure you are finishing the previous attempt? A new attempt should pull in new questions from the pool of questions tagged with those terms.

  • 🇳🇿New Zealand dominictaylor

    Thanks for the response. I’m not sure exactly why it was breaking but after some testing I was able to get the questions randomly being selected each time, as I was after, so it must have been as you suggested.

    Part of my confusion was that I was unsure of the configuration when setting up the quiz. For example, (see attached "add-quiz" screenshot). I wasn’t sure if I should set “Number of random questions” to the total number of questions I wanted, although I see it did increase to the number I added once I saved the quiz. So is this option for the "Random order" and "Random question" options? I need to explain this to the users so I'm double checking.

    To get what I wanted (12 questions, 3 categories) I selected “Categorised random questions”, created 3 Quiz terms and set “Number of questions” to 4. I'm assuming this is the correct procedure for what I want to do(?).

    Thanks for your time

  • 🇺🇸United States djdevin

    "Number of random questions" is ignored when you use categorized random questions. So your configuration is correct!

Production build 0.69.0 2024