-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathexample.qmd
111 lines (85 loc) · 2.91 KB
/
example.qmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
---
title: "Multiple Choice Quiz Example"
format:
revealjs:
quiz:
checkKey: 'c'
resetKey: 'q'
shuffleKey: 't'
allowNumberKeys: true
disableOnCheck: false
disableReset: false
shuffleOptions: true
includeScore: false
revealjs-plugins:
- quiz
---
## What is the capital of France? {.quiz-question}
- London
- [Paris]{.correct}
- Berlin
- Madrid
::: footer
Click on one of the options then click the check button. If you got it wrong click reset and try again.
:::
## What is the capital of the USA? {.quiz-question}
- Paris
- Berlin
- Madrid
- [Washington, D.C.]{.correct}
::: footer
Alternatively, you can select each option using your number keypad. For example, click "2" to select the second option.
:::
## What is the capital of Spain? {.quiz-question}
- Paris
- Berlin
- [Madrid]{.correct}
::: footer
You can use the "c" key to check your answer, the "q" key to reset the question, and the "t" key to shuffle the question slides.
:::
## What is the capital of Germany? {.quiz-question}
- Paris
- [Berlin]{.correct}
- Madrid
- London
::: footer
Keyboard shortcuts can be changed in the YAML header of your Quarto file. See [README.md](README.md) for more info.
:::
## Python lists {.quiz-question}
What is the value of x[2]?
<!-- ```{python}
#| eval: FALSE
#| echo: TRUE
x = [2, 3, 4]
x[2] = 4
print(x[2])
``` -->
- 2
- 3
- [4]{.correct}
::: footer
You can also include code or other content prior to the question.
:::
## {.quiz-question}
**What is the name of Ross and Carol's son in the TV show *"Friends"?***
- [Jack]{data-explanation="Jack is the name of Monica and Ross's father."}
- [Joey]{data-explanation="😲 Joey is one of the main characters, played by Matt LeBlanc."}
- [Ben]{.correct data-explanation="💯 Correct! Ben is the name of Ross and Carol's son."}
- [Chandler]{data-explanation="😂 Chandler is another main character, played by Matthew Perry."}
::: footer
You can specify an explanation for each option using the `data-explanation` attribute.
:::
## What is the formula for the area of a circle? {.quiz-question}
- [$πr^2$]{.correct}
- [$2πr$]{data-explanation="🫠 This is the formula for the circumference of a circle."}
- [$4πr^2$]{data-explanation="This is the formula for the surface area of a sphere."}
- [$\frac{4}{3}r^3$]{data-explanation="This is the formula for the volume of a sphere."}
::: footer
You can also include math expressions [using LaTeX](https://quarto.org/docs/visual-editor/technical.html#latex-and-html) in the options.
:::
## Which one is Chandler? {.quiz-question}
- [![](https://upload.wikimedia.org/wikipedia/en/d/da/Matt_LeBlanc_as_Joey_Tribbiani.jpg){height=90px}]{data-explanation="😬 This is Joey."}
- [![](https://upload.wikimedia.org/wikipedia/en/6/66/Matthew_Perry_as_Chandler_Bing.png){width=90px}]{.correct data-explanation="✅ Nicely done! This is Chandler."}
::: footer
Or you can try to embed images in the options.
:::