Introduction to Programming. June Marking Scheme

Similar documents
Introduction to Programming SAMPLE. Examination Paper. Time: 3 hours

Introduction to Programming. January Examination Paper. Time: 3 hours

Software Development Techniques. December Sample Exam Marking Scheme

Software Development Techniques. 26 November Marking Scheme

Fundamentals of Computing and Digital Literacy. Sample. Assignment title: Develop a Wiki. Marking Scheme

IT Skills. September Marking Scheme

Fundamentals of Computing and Digital Literacy. Sample. Marking Scheme

Applied Information and Communication Technology

Network Security and Cryptography. 2 September Marking Scheme

General Certificate of Secondary Education Digital Technology. Unit 5 Digital Development Practice MARK SCHEME

Network Security and Cryptography. December Sample Exam Marking Scheme

GCSE Computer Science

Reception Operations and Services

C A R I B B E A N E X A M I N A T I O N S C O U N C I L REPORT ON CANDIDATES WORK IN THE SECONDARY EDUCATION CERTIFICATE EXAMINATIONS MAY/JUNE 2010

Example Candidate Responses. Cambridge International AS & A Level Computer Science. Paper 2

State two analytical tools used to understand feasibility of a proposed application. Acceptable answer(s) Guidance Max mks

Examiners Report/ Lead Examiner Feedback Summer BTEC Level 3 Nationals in IT Unit 2: Creating Systems to Manage Information (31761H)

GCE FOOD TECHNOLOGY. Unit 4 Designing and Making Practice Report on the Examination June Version: 1.0

Cambridge International General Certificate of Secondary Education 0478 Computer Science June 2015 Principal Examiner Report for Teachers

GCSE Computer Science

A-LEVEL DESIGN AND TECHNOLOGY: FOOD TECHNOLOGY

Mark Scheme. June Pearson Level 2 Certificate in Digital Applications. Unit 5: Coding for the Web

POSTGRADUATE CERTIFICATE IN LEARNING & TEACHING - REGULATIONS

Unit 2: Collaborative Working

MARK SCHEME for the May/June 2011 question paper for the guidance of teachers 9691 COMPUTING. 9691/23 Paper 2 (Written Paper), maximum raw mark 75

Cambridge Assessment International Education Cambridge International Advanced Subsidiary and Advanced Level. Published

Introduction to Computer Science Midterm 3 Fall, Points

Unit 2: Creating Systems to Manage Information - Sample marking grid

BTEC Nationals IT - Unit2 FAQs

Systems and Principles Unit Syllabus

Higher Computing Science Software Design and Development - Programming Summary Notes

Cambridge Assessment International Education Cambridge International Advanced Subsidiary and Advanced Level. Published

BCS HIGHER EDUCATION QUALIFICATIONS - REGULATIONS

MARK SCHEME for the October/November 2013 series 9691 COMPUTING. 9691/23 Paper 2 (Written Paper), maximum raw mark 75

Mark Scheme. Edexcel Level 2 Certificate in Digital Applications. Unit 5: Coding for the Web

Cambridge Ordinary Level 2210 Computer Science November 2016 Principal Examiner Report for Teachers

2017 Mathematics Paper 1 (Non-calculator) Finalised Marking Instructions

Systems and Principles Unit Syllabus

POSTGRADUATE DIPLOMA IN RESEARCH METHODS

Studio and Location Sound Production

Cambridge Assessment International Education Cambridge International Advanced Subsidiary and Advanced Level. Published

CS 142 Style Guide Grading and Details

Graded Unit Title: Mechanical Engineering: Graded Unit 1

Object Oriented Programming with Visual Basic.Net

Student Performance Q&A:

Exemplar Candidate Work Part 1 of 2 GCE in Applied ICT. OCR Advanced GCE in Applied ICT: H715 Unit G057: Database design

Your route to becoming a Chartered IT Professional

Centre Guidance for Onscreen Tested Vocational Qualifications Edexcel BTEC Level 3 in Customer Service (QCF)

Designing and Developing a Website. 6 August Marking Scheme

Examiners Report. January Pearson Edexcel Functional Skills ICT Level 1 (FST01)

RM Assessor guide to completing the standardisation process (Marker guide)

Cambridge International General Certificate of Secondary Education 0478 Computer Science June 2016 Principal Examiner Report for Teachers

Enquiries about results guide (International) 2018 A guide for exams officers

Read this before starting!

Student Performance Q&A:

BCS HIGHER EDUCATION QUALIFICATIONS Level 4 Certificate in IT. April 2013 EXAMINERS REPORT. Software Development

Cambridge Assessment International Education Cambridge International Advanced Subsidiary and Advanced Level. Published

DEPARTMENT OF COMPUTER AND MATHEMATICAL SCIENCES UNIVERSITI TEKNOLOGI MARA CAWANGAN PULAU PINANG

Introduction to VBA for Excel-Tutorial 7. The syntax to declare an array starts by using the Dim statement, such that:

Enquiries about results guide (UK) 2018 A guide for exams officers

Introduction to Computer Science and Business

Documentary Evidence - Guidance for Education and Training Providers

Vba Variables Constant and Data types in Excel

Cambridge Assessment International Education Cambridge International Advanced Subsidiary and Advanced Level

PART A : MULTIPLE CHOICE Circle the letter of the best answer (1 mark each)

BCS THE CHARTERED INSTITUTE FOR IT. BCS HIGHER EDUCATION QUALIFICATIONS BCS Level 5 Diploma in IT OBJECT ORIENTED PROGRAMMING

Cambridge Ordinary Level 2210 Computer Science June 2016 Principal Examiner Report for Teachers

GCSE Computer Science

1007 Imperative Programming Part II

AP Computer Science A 2004 Scoring Commentary

Designing and Developing a Website. December Sample Exam Marking Scheme

Unit title: Programming for Mobile Devices (SCQF level 6)

Step-by-step. Functional Skills Claims. Interchange. guide. Making online claims for Functional Skills qualifications via Interchange

C++ (Non for C Programmer) (BT307) 40 Hours

Mark Scheme (Results) January Pearson Edexcel Level 2 Diploma In Digital Applications. Unit 5: Coding for the Web

MARK SCHEME for the May/June 2011 question paper for the guidance of teachers 9691 COMPUTING. 9691/22 Paper 2 (Written Paper), maximum raw mark 75

New Concepts. Lab 7 Using Arrays, an Introduction

Quiz1 Fall 2007 October 2 nd, UNIVERSITY OF WINDSOR Fall 2007 QUIZ # 1 Solution. Examiner:Ritu Chaturvedi Dated :October 2nd, 2007.

Course Report Computing Science Advanced Higher

VB Net Debugging (Console)

1.1 Use a presentation package to prepare documents for a printed slide presentation

Name :. Roll No. :... Invigilator s Signature : INTRODUCTION TO PROGRAMMING. Time Allotted : 3 Hours Full Marks : 70

Principal Examiner Feedback. November Functional Skills ICT Level 2 (FST02)

CS110D: PROGRAMMING LANGUAGE I

Advanced Financial Modeling Macros. EduPristine

Cambridge Assessment International Education Cambridge International General Certificate of Secondary Education. Published

Higher National Unit specification: general information. Graded Unit 2

AP Computer Science A 2003 Scoring Guidelines

Homework #3 CS2255 Fall 2012

UNIT 1. Introduction to Microsoft.NET framework and Basics of VB.Net

Mark Scheme. Additional Sample Assessment Materials. Pearson BTEC Level 3 - Computing. Unit 1: Principles of Computer Science

Levels 1-3 Qualifications in Engineering (2850)

Principal Examiner Feedback. May Functional Skills ICT Level 2 (FST02)

ITEC136 - Lab 2 Population

Wednesday 18 May 2016 Morning

ME 142 Engineering Computation I. Debugging Techniques

SOCIETY OF HEALTH AND PHYSICAL EDUCATORS AMERICA HEALTH EDUCATION (FORMERLY AAHE) (SHAPE Health Education)

Certified LabVIEW Associate Developer Exam. Test Booklet

Unit Assessment Guide

Principal Examiner Feedback. March Functional Skills ICT. Level 2 (FST02)

Transcription:

Introduction to Programming June 2015 Marking Scheme This marking scheme has been prepared as a guide only to markers. This is not a set of model answers, or the exclusive answers to the questions, and there will frequently be alternative responses which will provide a valid answer. Markers are advised that, unless a question specifies that an answer be provided in a particular form, then an answer that is correct (factually or in practical terms) must be given the available marks. If there is doubt as to the correctness of an answer, the relevant NCC Education materials should be the first authority. Throughout the marking, please credit any valid alternative point. Where markers award half marks in any part of a question, they should ensure that the total mark recorded for the question is rounded up to a whole mark.

Background information Complete the following computer programming tasks using Visual Basic. For each task you must test the programming code you create. The evidence you must produce is a Word document containing the following for each task. Required outcomes Simple test criteria The Visual Basic program code, with relevant comments (i.e. annotated) Screenshots of the user interface Screenshots of the output generated when the program code is run It would be a good idea to use the Windows Snipping tool to assemble this Word document. You do not have to provide any general commentary on your work. You do not have to provide any history of what debugging you may have done. It is very important that the program code is clear, the outputs are designed to be easy to understand and your Word document is well presented. A formula sheet containing the VB syntax for common programming structures is provided at the back of the examination paper and you may refer to this during the exam. Use of your own notes during the examination is not allowed. Page 2 of 13

Answer ALL questions Question 1 Marks Write and test a program to covert pints into litres. 1 litre = 1.7598 pints. The program should accept user input via a textbox, and display the output using a label. The program should work for real numbers as well as whole numbers (e.g. it should accept 3.6 pints, 0.54 pints etc.). Suitable user interface with textbox, button and labels o Award 2 marks for a neat interface with all required components o Award 1 mark if there are missing components or the layout is very poorly designed. o Award 0 marks if not attempted Program handles data input appropriately Program stores data as acceptable data type (double or float) Program calculates conversion correctly (litres / 1.798) o 2 marks for correct calculation o 1 mark if the calculation is correct but there are rounding errors due to using integer data type o 0 marks for incorrect formula Program successfully displays correct answer Evidence provided of testing with valid data. Evidence provided of testing with invalid data (e.g. strings) o 2 marks for testing with 2 types of invalid data (e.g. with a string and with null input). o 1 mark for testing, 1 type of invalid data o 0 marks if not attempted 10 Total 10 Marks Page 3 of 13

Question 2 Marks A restaurant has carried out a survey asking its customers to vote for their favourite dessert. Write and test a program that allows the user to enter the name of each dessert and the number of votes it received. The program must allow the user to enter details for 10 desserts. This data should be stored in two separate arrays (one array for the dessert names and another array for the number of votes received). The dessert names should be stored as strings. The number of votes should be stored as whole numbers. The input data should be validated before being entered into the array. Names must be at least 4 characters long and cannot contain more than 25 characters. Only values between 0 and 300 should be accepted and stored in the number of votes array (the number of people who voted in the survey is 300). If an invalid entry is attempted, a message should be displayed informing the user that the entry will not be stored and that the name must be between 4 and 25 characters long and that a value between 0 and 300 must be entered for the number of votes received by the dessert. Once the arrays are full, the Input data button should be disabled and the Show contents button should be enabled which, when pressed, will print out the dessert name and number of votes received for each dessert, in the order entered, to a label. Complete an Object Definition Sheet for this task. Suitable user interface with textbox, buttons and labels Award 3 marks if the interface is well laid out, contains all required controls, and controls are disabled/invisible or enabled as appropriate (e.g. Input data button and textboxes should be enabled, Show contents button should be disabled/hidden at form load time) Award 2 marks if all components are included on the form but are poorly laid out or are not enabled/disabled as requested Award 1 mark if some components are missing Award 0 marks if not attempted Array of correct size and data type (string) correctly declared for the dessert names Award 2 marks if both size and data type are correct and declaration is correct syntax Award 1 mark if either the size or the data type are inappropriate Award 0 marks for incorrect declaration that will not compile Array of correct size and data type (integer) correctly declared for number of votes received Award 2 marks if both size and data type are correct and declaration is correct syntax Award 1 mark if either the size or the data type are inappropriate Award 0 marks for incorrect declaration that will not compile Program accepts data input of dessert names Award 1 mark if textbox is enabled Award 0 marks if not attempted or textbox is disabled 54 Page 4 of 13

Marks Program accepts data input of number of votes received for each dessert Award 2 marks if textbox is enabled and either the program handles data type conversion (from string to integer) or the textbox properties are set so that it only accepts numerical input Award 1 mark if textbox is enabled but there is no limiting of data type input or explicit conversion to integer Award 0 marks if not attempted Appropriate data validation of input for dessert names Award 2 marks if validation successfully excludes dessert names shorter than 4 characters and longer than 25 characters (through selection statement(s)) Award 1 mark if only 1 of the checks is successful Award 0 marks if not attempted or does not work for either of the checks Appropriate data validation of input for number of votes received for the dessert Award 3 marks if validation successfully excludes numbers lower than 0, numbers higher than 300 (through selection statement(s)) and data of the wrong type (either through textbox properties or a selection statement) Award 2 marks if 2 of the 3 checks are successful Award 1 mark if only 1 of the checks is successful Award 0 marks if not attempted or if none of the checks are successful Display appropriate message for invalid input Award 1 mark if an appropriate message is displayed when invalid input is entered Program fills arrays successfully Award 1 mark for declaring counter and initialising appropriately to 0 Award 1 mark for incrementing counter whenever the button is clicked and the data passes validation Award 1 mark for storing the dessert name data in the next vacant element of the dessert names array Award 1 mark for storing the number of votes received by the dessert in the next vacant element of the votes received array Award 1 mark for preventing the possibility of trying to write to an out of bounds location (i.e. element 5 of either array, or any element not between 0 4). Award 1 mark for writing the data validation as a separate function rather than as part of the button click code Enabling and disabling controls appropriately Award 3 marks for disabling the Input data button and the textboxes once the array is full and enabling the Show contents button once the array is full Award 2 marks for doing 2 of the 3 above Award 1 mark for only changing one of the 3 controls Award 0 marks if not attempted Page 5 of 13

Marks Use of a loop to step over the arrays and access the contents Award 1 mark for declaring loop counter and initialising to 0 Award 1 mark for correct continuation condition Award 1 mark for incrementing the loop correctly Award 1 mark for accessing the contents of the dessert names array Award 1 mark for accessing the contents of the votes received array Successfully displaying the contents of the array Award 2 marks for writing the code to access and display the contents as a separate function rather than as part of the button click code Award 1 mark for successfully adding data from the dessert names array to a label Award 1 mark for successfully adding data from the votes received array to a label Award 2 marks for successfully pairing up the dessert names and votes received line by line on the label output Award 2 marks if all 10 dessert names and votes received are added and displayed in order Evidence provided of testing with valid data Award 2 marks for 2 or more tests with valid data Award 1 mark if only one test with valid data Award 0 marks if not attempted Evidence provided of testing dessert names with extreme data (e.g. ABCD, ABCDEFGHIJKLMNOPQRSTUVWXY ) Award 1 marks if there is evidence of testing with extreme data Award 0 marks if not attempted Evidence provided of testing votes received with extreme data (e.g. 0, -1, 300, 301) Award 2 marks if both boundaries of the valid range of votes received are tested Award 1 mark if only 1 boundary is tested Award 0 marks if not attempted Evidence provided of testing dessert names with invalid data Award 2 marks if suitable testing with 2 types of invalid data is attempted (e.g. a null value and a real number) Award 1 mark if only one type of invalid data is tested Award 0 marks if not attempted Evidence provided of testing number of votes received with invalid data Award 2 marks if suitable testing with 2 types of invalid data is attempted (e.g. a null value and a string) Award 1 mark if only one type of invalid data is tested Award 0 marks if not attempted Code suitably commented Award 3 marks if the code is fully commented for all variable declarations, functions, loops and selection statements Award 2 marks for a good level of commenting but one or two sections not fully commented Award 1 mark if the code is sparsely commented, or there are lots of comments but the comments are confusing or inaccurate Award 0 marks if there are no comments, or no helpful comments Page 6 of 13

Marks Object Definition Sheet Award 4 marks for fully complete Object Definition Sheet with all nondefault property values and all candidate-written event procedures Award 3 marks if 1 or 2 property values or procedures are omitted Award 2 marks if only partially completed (3 or more entries missing but at least 2 correct entries) Award 1 mark if at least one correct entry Award 0 marks if not attempted Total 54 Marks Question 3 Extend the program from Question 2 so that it includes a button which, when pressed, will find and display the name of the dessert that received the highest number of votes, along with the number of votes it received, followed by the name of the dessert that received the second highest number of votes, along with the number of votes it received. 21 Page 7 of 13

Marks Create the required additional GUI components Award 2 marks for adding a suitably named button and a label to display the number of votes received by each dessert Award 1 mark if only part of the additional required components are added Award 0 marks if no additional GUI components are added Find the dessert with the highest number of votes Award 1 mark for declaring a variable to store the highest number of votes Award 1 mark for declaring a variable to store the second highest number of votes Award 1 mark for declaring a variable to store the location at which the highest vote was found Award 1 mark for declaring a variable to store the location at which the second highest vote was found Award 1 mark for setting highest number of votes to a suitable initial value Award 1 mark for setting second highest number of votes to a suitable initial value Award 2 marks for looping over the votes received array Award 2 marks for a suitable selection statement to update the highest number of votes (e.g. if current element value > highest number of votes) Award 3 marks for a suitable selection statement to update the second highest number of votes (if the current element was the highest value then update the highest number of votes variable, otherwise if it was the same value or lower than the highest number of votes value then compare it against the second highest number of votes variable and update that if it is higher than the current value stored there) Award 1 mark for updating the variable used to store the location at which the highest vote is located when the value of highest vote is updated. Award 1 mark for updating the variable used to store the location at which the second highest vote is located when the value of the highest vote is updated. Award 1 mark for accessing the name of the dessert with the highest number of votes using the variable storing the location at which the highest number of votes was received to identify which element in the dessert names array to access Award 1 mark for accessing the name of the dessert with the second highest number of votes using the variable storing the location at which the second highest number of votes was received to identify which element in the dessert names array to access Award 2 marks for displaying the correct results in the correct order Total 21 Marks Page 8 of 13

Question 4 Marks The data needs to be stored permanently. Extend the program from Question 3 so that it writes out each dessert name and the corresponding number of votes to a text file called SurveyResults. The dessert names and number of votes they received should be paired on the same line, with the first dessert name followed by the number of votes they received on the same line with no spaces between them, and so on for all 10 desserts and votes received. There should be a Save results button which will write the data to file when pressed. This button should not be enabled until all 10 dessert names and numbers of votes received have been entered. Test the extended functionality of the program. Award 1 mark for correct import statement for System.IO Award 1 mark for adding required GUI component ( Save results button) Award 1 mark for having the Save results button disabled when the program is started and enabling it when all 10 entries have been made Award 2 marks for a variable to store the file-path and data validation to ensure it is not null Award 1 mark for correctly declaring a StreamWriter Award 1 mark for initialising StreamWriter passing in the filepath Award 2 marks for looping over both arrays and appending the relevant number of votes to each dessert name for writing out to file in the required format Award 1 mark for using the WriteLine method to write the contents out to file Award 1 mark for closing the connection to the file Award 1 mark for evidence of creating the file Award 1 mark for use of a function or functions rather than placing the write to file code in the button click Sub Award 2 marks for evidence of testing (e.g. with null filename, with suitable filename but empty array, with suitable filename and full array with valid values) 15 Total 15 Marks Page 9 of 13

Submission guidelines Once you have completed the tasks, carefully check the contents of the Word file so that it is a complete record of your work and is presented according to the guidance notes above. Submit this Word file for assessment via suitable media. End of paper Page 10 of 13

Formula sheet Declaring variables Variable declarations have the following format: Dim [variable_name] As [data-type] Code examples Dim mywholenumber As Integer Dim myrealnumber as Double Dim myname As String For loops For loops have the following format: Dim [loop_counter_name] As Integer For [loop_counter_name] = [start_num] To [end_num] do the code here Next Code example Dim counter As Integer For counter = 0 To 5 Console.WriteLine( The counter is at: & counter) Next While loops While loops have the following format: While [condition] do the code here Next Code example Dim mynum As Integer While mynum < 12 Console.WriteLine( The value of mynum is: & mynum) mynum=mynum+1 End While Page 11 of 13

If statements If statements have the following format: If [condition] do the code here End If Code example Dim mynum As Integer If mynum < 12 Console.WriteLine( The value of mynum is: & mynum) End While Arrays Arrays are declared and the number of elements set as follows: Dim [array_name]([number_of_elements]) As [data_type] Code example Dim mynums(12) As Integer To store a value in an array we need to indicate which element we want to store the value in: mynums[0] = 15 stores the value 15 in element 0 of the array To retrieve a value from an array we need to indicate which element we wish to access: temp = mynums[2] copy contents of element 2 of mynums to temp To loop over an array using a for loop: Dim counter As Integer For counter = 0 to 11 temp = mynums[counter] Console.WriteLine( The counter is at: & counter) Next Page 12 of 13

Learning Outcomes matrix Question Learning Outcomes assessed 1 1, 4, 6 Yes 2 1, 2, 3, 4, 6 Yes 3 1, 2, 6 Yes 4 1, 2, 5, 6 Yes Grade descriptors Marker can differentiate between varying levels of achievement Learning Outcome Pass Merit Distinction Understand the Visual Basic (VB) Integrated Development Environment (IDE) and development framework adequate level of robust level of Understand the programming constructs of sequence and iteration Understand the concept of project documentation Understand data capture and validation Implement a program that uses iteration and sequence constructs Implement a program that uses screen controls Implement a program that uses serial files Implement a program that uses arrays adequate level of adequate level of adequate level of ability to perform the task ability to perform the task ability to perform the task ability to perform the task robust level of robust level of robust level of ability consistently well ability consistently well ability consistently well ability consistently well highly comprehensive level of highly comprehensive level of highly comprehensive level of highly comprehensive level of ability to the highest standard ability to the highest standard ability to the highest standard ability to the highest standard Page 13 of 13