mc <- new("MultipleChoice",
identifier = "id_task_1234",
title = "Multiple Choice Task",
content = list("Pick up the right options"),
prompt = "Plain text, can be used instead of content",
points = c(1, -1, 1, -1),
feedback = list(new("WrongFeedback", content = list("Wrong answer"))),
calculator = "scientific-calculator",
files = "text_book.pdf",
choices = c("option 1", "option 2", "option 3", "option 4"),
choice_identifiers = c("ChoiceA", "ChoiceB", "ChoiceC", "ChoiceD"),
shuffle = TRUE,
orientation = "vertical")
Run the code above in your browser using DataLab