// Numbas version: exam_results_page_options {"name": "Cost for a pre-roll campaign", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"name": "Cost for a pre-roll campaign", "tags": [], "metadata": {"description": "

Given a campaign budget and a number of impressions, calculate either the Cost per View, or the Cost per 1000 Views.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

A pre-roll ad is a video advertisement that automatically plays directly before a feqtured video on both mobile and desktop.

\n

You have bought a pre-roll video campaign and paid \\${separateThousands(campaign,\",\")} for {separateThousands(impressions,\",\")} impressions. 

", "advice": "

The CPV (Cost per View) for the campaign = cost for one impression =  \\${SeparateThousands(campaign,\",\")} $\\div$ {SeparateThousands(impressions,\",\")} = \\${precround(campaign/impressions,4)}

\n

The CPM (Cost per Thousand) for the campaign = 1,000 $\\times$ CPV = 1,000 $\\times$ \\${precround(campaign/impressions,4)} = \\${precround(campaign*1000/impressions,2)}.

", "rulesets": {}, "extensions": [], "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"idx": {"name": "idx", "group": "Ungrouped variables", "definition": "random(0,1)", "description": "", "templateType": "anything", "can_override": false}, "typestring": {"name": "typestring", "group": "Ungrouped variables", "definition": "[\"CPV (cost per view)\",\"CPM (cost per thousand impressions)\"][idx]", "description": "", "templateType": "anything", "can_override": false}, "impressions": {"name": "impressions", "group": "Ungrouped variables", "definition": "random(10000..1000000#10000)", "description": "", "templateType": "anything", "can_override": false}, "campaign": {"name": "campaign", "group": "Ungrouped variables", "definition": "random(10000..500000#10000)", "description": "", "templateType": "anything", "can_override": false}, "minval": {"name": "minval", "group": "Ungrouped variables", "definition": "floor(val*100)/100", "description": "", "templateType": "anything", "can_override": false}, "maxval": {"name": "maxval", "group": "Ungrouped variables", "definition": "ceil(val*100)/100", "description": "", "templateType": "anything", "can_override": false}, "val": {"name": "val", "group": "Ungrouped variables", "definition": "[campaign/impressions,campaign/impressions*1000][idx]", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["idx", "typestring", "impressions", "campaign", "minval", "maxval", "val"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

You will advise your client that you have agreed a {typestring} of \\$[[0]] for the campaign.

", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "minval", "maxValue": "maxval", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always", "contributors": [{"name": "Susan McGlynn", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2148/"}, {"name": "Merryn Horrocks", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4052/"}]}]}], "contributors": [{"name": "Susan McGlynn", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2148/"}, {"name": "Merryn Horrocks", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4052/"}]}