// Numbas version: finer_feedback_settings
{"name": "Andrew's copy of Sets 2-4", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"preamble": {"css": "", "js": ""}, "tags": [], "functions": {"mod_set": {"definition": "//returns all integers which are divisible by c betweeen a and b\nvar l=[];\nfor(var i=a;ia) $A=\\{x \\in \\mathbb{N}\\;|\\;\\var{a} \\leq x \\leq \\var{b}\\text{ and } x \\text{ is divisible by }\\var{c}\\}$.
\n$A=\\;$[[0]]
\nb) $B=\\{x \\in \\mathbb{Z}\\;|\\;\\var{d} \\leq x \\leq \\var{f}\\text{ and } x^2 \\lt \\var{g}\\}$.
\n$B=\\;$[[1]]
\nc) $C=\\{x \\in \\mathbb{Z}\\;|\\;\\var{d} \\leq x \\leq \\var{f}\\text{ and } x^2 \\gt \\var{g}\\}$.
\n$C=\\;$[[2]]
\nd) $A \\cap C=\\;$[[3]]
\n\nNote that you input sets in the form set(a,b,c,..,z)
.
\nFor example set(1,2,3)
gives the set $\\{1,2,3\\}$.
\nThe empty set is input as set()
.
\nAlso some labour saving tips:
\nIf you want to input all integers between $a$ and $b$ inclusive then instead of writing all the elements you can input this as set(a..b)
.
\nIf you want to input all integers between $a$ and $b$ inclusive in steps of $c$ then this is input as set(a..b#c)
. So all odd integers from $-3$ to $28$ are input as set(-3..28#2).
", "variableReplacementStrategy": "originalfirst", "showFeedbackIcon": true, "marks": 0}], "rulesets": {}, "variable_groups": [], "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["a", "b", "c", "answer_set1", "d", "f", "g", "answer_set2", "r", "answer_set3", "answer_set4"], "extensions": [], "statement": "Write the following sets in enumerated form.
\nNote that you enter an enumerated set such as $\\{35,67,99\\}$ as set(35,67,99)
.
\n", "metadata": {"licence": "Creative Commons Attribution 4.0 International", "description": ""}, "variables": {"c": {"definition": "random(3..7)", "templateType": "anything", "description": "", "name": "c", "group": "Ungrouped variables"}, "f": {"definition": "random(10..25)", "templateType": "anything", "description": "", "name": "f", "group": "Ungrouped variables"}, "answer_set2": {"definition": "set(-r+1..r-1)and set(d..f)", "templateType": "anything", "description": "", "name": "answer_set2", "group": "Ungrouped variables"}, "answer_set4": {"definition": "answer_set1 and answer_set3", "templateType": "anything", "description": "", "name": "answer_set4", "group": "Ungrouped variables"}, "d": {"definition": "random(-25..-5)", "templateType": "anything", "description": "", "name": "d", "group": "Ungrouped variables"}, "answer_set1": {"definition": "set(mod_set(a,b,c))", "templateType": "anything", "description": "", "name": "answer_set1", "group": "Ungrouped variables"}, "b": {"definition": "a+random(12..30)", "templateType": "anything", "description": "", "name": "b", "group": "Ungrouped variables"}, "r": {"definition": "random(8..15)", "templateType": "anything", "description": "", "name": "r", "group": "Ungrouped variables"}, "answer_set3": {"definition": "set(d..f) and(set(d-1..-r-1) or set(r+1..f+1))", "templateType": "anything", "description": "", "name": "answer_set3", "group": "Ungrouped variables"}, "a": {"definition": "random(8..20)", "templateType": "anything", "description": "", "name": "a", "group": "Ungrouped variables"}, "g": {"definition": "r^2", "templateType": "anything", "description": "", "name": "g", "group": "Ungrouped variables"}}, "name": "Andrew's copy of Sets 2-4", "advice": "", "type": "question", "contributors": [{"name": "Andrew Dunbar", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/770/"}]}]}], "contributors": [{"name": "Andrew Dunbar", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/770/"}]}