[This article was first published on R/exams, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here)
Want to share your content on R-bloggers? click here if you have a blog, or here if you don’t.
Exercise template for a very basic arithmetic task, namely computing the sum of two random numbers minus their difference.
Preview:
The result of the calculation is (52 + 30) – (52 – 30) = 82 – 22 = 60.
The result of the calculation is (32 + 22) – (32 – 22) = 54 – 10 = 44.
The result of the calculation is (42 + 31) – (42 – 31) = 73 – 11 = 62.
Description:
Minimal arithmetic task (sum of two numbers minus their difference) with randomly-drawn numbers but only short text description and no mathematical notation in LaTeX.
Randomization:
Random numbers
Mathematical notation:
No
Verbatim R input/output:
No
Demo code:
library("exams") set.seed(403) exams2html("sumdiff.Rmd") set.seed(403) exams2pdf("sumdiff.Rmd") set.seed(403) exams2html("sumdiff.Rnw") set.seed(403) exams2pdf("sumdiff.Rnw")
Related