Template for a Quiz

This worksheet is a template to make a quiz. To use it, you have to :[br]1. Precise the number of questions. This number is represented with the numeric variable n.[br]2. Create texts Q1, Q2, Q3, … each containing one question.[br]3. Create a list Q ={Q1,Q2, Q3, …} [br]4. Create texts A1, A2, A3, ... containing the answer A) to the corresponding question.[br]5. Create a list A = {A1, A2, A3, …}[br]6. Make the same things as in 4. and 5. for the answers B, C, and D.[br]7. Create a list of good GA of good answers.[br]8. Create 4 Boolean variables a, b, c, and d to check the good answer for each question.[br]9. Create a Boolean variable Good that will be true when the good answer is checked and false otherwise.[br]10. Create a numeric variable Score to count the good answers.[br]11. Create a numeric variable q for the number of current question.[br]12. Create a text variable Ans = If(a, "a", If(b, "b", If(c, "c", If(d, "d", "?")))) to keep the selected answer.[br]13. Create a button Start with script [br]   q=0[br]   a=false[br]   b=false[br]   c=false[br]   d=false[br]   Good=Ans ≟ Element[GA, q][br]   Score=If[q==0,0,If[Good,Score+1,Score]][br]14. Create a button New Question to get a new question. The script of this button is[br]  Score=If[Good,Score+1,Score][br]   q=q+1[br]  a=false[br]  b=false[br]   c=false[br]  d=false[br]15. Attach to each of the Boolean variable an update script as[br]   b=false a=false a=false a=false[br]   c=false for variable a, c= false for b b=false for c b=false for d[br]  d=false d=false d=false c=false

Information: Template for a Quiz