HALF-YEARLY EXAMINATIONS FEBRUARY Subject: Computing Form: 4 Time: 1 ½ hours MARKING SCHEME

Similar documents
HALF-YEARLY EXAMINATIONS FEBRUARY

FORM 4 (Option) COMPUTING TIME: 1 hr 30 min

SECONDARY SCHOOL, L-IMRIEĦEL HALF YEARLY EXAMINATIONS 2016/2017

AP Computer Science Unit 1. Programs

KULLEĠĠ SAN BENEDITTU Secondary School, Kirkop

FORM 5 COMPUTING TIME: 1h 45min

Introduction to Java Unit 1. Using BlueJ to Write Programs

AP Computer Science Unit 1. Writing Programs Using BlueJ

PROGRAMMING FUNDAMENTALS

Zheng-Liang Lu Java Programming 45 / 79

Fundamentals of Programming Data Types & Methods

Introduction to Computer Science Unit 2. Notes

M105: Introduction to Programming with Java Midterm Examination (MTA) Makeup Spring 2013 / 2014

Getting started with Java

Formatting Output & Enumerated Types & Wrapper Classes

World Inside a Computer is Binary

CIS133J. Working with Numbers in Java

1. [3 pts] What is your section number, the period your discussion meets, and the name of your discussion leader?

Do not open this examination paper until instructed to do so. Section A: answer all the questions. Section B: answer all the questions.

CS16 Exam #1 7/17/ Minutes 100 Points total

Section 2.2 Your First Program in Java: Printing a Line of Text

false, import, new 1 class Lecture2 { 2 3 "Data types, Variables, and Operators" 4

Selections. EECS1021: Object Oriented Programming: from Sensors to Actuators Winter 2019 CHEN-WEI WANG

CSC 1051 Algorithms and Data Structures I. Midterm Examination February 24, Name: KEY 1

COMP-202B - Introduction to Computing I (Winter 2011) - All Sections Example Questions for In-Class Quiz

Midterm Examination (MTA)

Internal Data Representation

CSc 2010 Principles of Computer Science, Fall 2013 Practice Problems for Midterm 3* * 3 17 % 9-20 % (26 / 7) "2"

BSc. (Hons.) Software Engineering. Examinations for / Semester 2

Exercise: Using Numbers

Supplementary Test 1

1 Definitions & Short Answer (4 Points Each)

Java Foundations: Introduction to Program Design & Data Structures, 4e John Lewis, Peter DePasquale, Joseph Chase Test Bank: Chapter 2

AP CS Unit 3: Control Structures Notes

Data and Variables. Data Types Expressions. String Concatenation Variables Declaration Assignment Shorthand operators. Operators Precedence

Binary Values. CSE 410 Lecture 02

Introduction to Computer Science Unit 2. Notes

1 class Lecture2 { 2 3 "Elementray Programming" / References 8 [1] Ch. 2 in YDL 9 [2] Ch. 2 and 3 in Sharan 10 [3] Ch.

Practice Midterm 1. Problem Points Score TOTAL 50

false, import, new 1 class Lecture2 { 2 3 "Data types, Variables, and Operators" 4

false, import, new 1 class Lecture2 { 2 3 "Data types, Variables, and Operators" 4

Full file at

CS & IT Conversions. Magnitude 10,000 1,

FINAL QUIZ. Marlene Galea

University of Cape Town ~ Department of Computer Science. Computer Science 1015F ~ 2007

University of Cape Town ~ Department of Computer Science Computer Science 1015F ~ June Exam

Exam 1. CSC 121 Spring Lecturer: Howard Rosenthal. March 1, 2017

6. Under which of the following categories is a laptop computer classified? (1) Microcomputer (2) Minicomputer (3) Mainframe (4) Supercomputer

Department of Computer Science Purdue University, West Lafayette

CS2141 Software Development using C/C++ C++ Basics

Programming: Java. Chapter Objectives. Chapter Objectives (continued) Program Design Including Data Structures. Chapter 7: User-Defined Methods

Pace University. Fundamental Concepts of CS121 1

Software Practice 1 Basic Grammar

Give one example where you might wish to use a three dimensional array

CEN 414 Java Programming

Programming with Java

Date: Dr. Essam Halim

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

Full file at

Motivating Examples (1.1) Selections. Motivating Examples (1.2) Learning Outcomes. EECS1022: Programming for Mobile Computing Winter 2018

Data Types. 1 You cannot change the type of the variable after declaration. Zheng-Liang Lu Java Programming 52 / 87

CIS 110 Introduction To Computer Programming. February 29, 2012 Midterm

IT 1003 Introduction to Programming (New)

COMP 202 Java in one week

CSE 201 JAVA PROGRAMMING I. Copyright 2016 by Smart Coding School

What did we talk about last time? Examples switch statements

Introduction to Computer Science II (CSI 1101)

a) Answer all questions. b) Write your answers in the space provided. c) Show all calculations where applicable.

false, import, new 1 class Lecture2 { 2 3 "Data types, Variables, and Operators" 4

Entry Point of Execution: the main Method. Elementary Programming. Learning Outcomes. Development Process

Review Chapters 1 to 4. Instructor: Scott Kristjanson CMPT 125/125 SFU Burnaby, Fall 2013

Representation of Non Negative Integers

2.8. Decision Making: Equality and Relational Operators

CSCI 1226 Sample Midterm Exam

Midterm Exam. CSCI 2132: Software Development. March 4, Marks. Question 1 (10) Question 2 (10) Question 3 (10) Question 4 (10) Question 5 (5)

University of Cape Town Department of Computer Science. Computer Science CSC115F. June 2003/2004 Supplementary Exam

St. Catherine s High School

Computational Expression

Section 003 Fall CS 170 Exam 1. Name (print): Instructions:

Primitive Data, Variables, and Expressions; Simple Conditional Execution

Choose 3 of the 1 st 4 questions (#'s 1 through 4) to complete. Each question is worth 12 points.

POST GRADUATE DIPLOMA IN LIBRARY AUTOMATION AND NETWORKING (PGDLAN)

Software Practice 1 - Basic Grammar Basic Syntax Data Type Loop Control Making Decision

data_type variable_name = value; Here value is optional because in java, you can declare the variable first and then later assign the value to it.

Introduction to Java Applications

1. [3 pts] What is your section number, the period your discussion meets, and the name of your discussion leader?

LAB 1 Binary Numbers/ Introduction to C. Rajesh Rajamani. ME 4231 Department of Mechanical Engineering University Of Minnesota

Selec%on and Decision Structures in Java: If Statements and Switch Statements CSC 121 Spring 2016 Howard Rosenthal

Connecting with Computer Science, 2e. Chapter 15 Programming II

BCS THE CHARTERED INSTITUTE FOR IT. BCS HIGHER EDUCATION QUALIFICATIONS BCS Level 4 Certificate in IT SOFTWARE DEVELOPMENT

Digital Arithmetic. Digital Arithmetic: Operations and Circuits Dr. Farahmand

Question: Total Points: Score:

Decimal & Binary Representation Systems. Decimal & Binary Representation Systems

Java is an objet-oriented programming language providing features that support

UNIT 7A Data Representation: Numbers and Text. Digital Data

Groups of two-state devices are used to represent data in a computer. In general, we say the states are either: high/low, on/off, 1/0,...

Fall 2017 CISC124 9/16/2017

Number Systems (2.1.1)

Java Classes: Math, Integer A C S L E C T U R E 8

AP Computer Science Unit 1. Writing Programs Using BlueJ

Transcription:

HALF-YEARLY EXAMINATIONS FEBRUARY 2017 Subject: Computing Form: 4 Time: 1 ½ hours MARKING SCHEME 1

Section A Answer all the questions in the space provided. 1. Use 5 (five) of the following terms to identify the areas described below. Computer Process Control Teleshopping POS Terminals DBMS E-Commerce Robotics Medical Diagnosis Programming Intelligent Cars a. A digital computer is used to direct the operations of a manufacturing process. b. Sensors and actuators built into the mechanical body with computer software to execute the desired tasks. c. The idea of doing business electronically over the Internet. d. Managing a database to assist health providers in reaching a conclusion. e. In the future, collision-avoidance will be advanced enough to totally drive a car without any driver assistance. Computer Process Control Robotics E-Commerce Medical Diagnosis Intelligent Cars 2. Identify whether the below are properties of Off-the-Shelf or Tailor-Made software. a. Cheaper in price Off-the-Shelf b. Does not contain extra options other than those needed Tailor-Made c. Saves time and effort of development Off-the-Shelf d. May come with poor printed documentation Off-the-Shelf e. Developed for some specific organisation Tailor-Made 3. Two's complement is a clever way of storing integers so that common math problems are very simple to implement. a. Convert 83 to 8-bit 2 s complement binary. Award 1 mark for a completely correct answer. Space for working Answer: 01010011 b. Convert -60 to 8-bit 2 s complement binary Award 1 mark for a completely correct answer. Space for working Answer: 11000100 2

4. This question is about ranges and binary addition. a. What is the smallest negative number that can be represented in a 2 s complement 8-bit register? -128 b. What is the largest negative number that can be represented in a 2 s complement 8-bit register? -1 c. Using an 8-bit unsigned register, perform binary addition for 75+44. [1 mark for correct conversions to binary, 1 mark for correct answer] 75 = 01001011, 44 = 00101100, 119 = 01110111 d. What is the technical term used to describe a situation where the result of an 8-bit binary addition contains 9 bits? Numeric Overflow 5. Identify whether the below are examples of a Syntax, Logical or Runtime error. a. Caused by incorrect use of the programming language. Syntax b. Caused by inaccurately reasoning out the solution. Logical c. Caused by an unexpected event during execution. Runtime d. Easiest error to identify. Syntax e. Attempting to read a file which does not exist. Runtime 6. The Java program below does not compile. Identify the line where there is: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 public class Prog1 { } public static void main(string[] args) { } int num = Keyboard.readInt(); if (num % 2 = 0) { System.out.println("ODD"); } else { System.out.println("EVEN"); } a. An input Line 5 b. An output Line 7 / Line 10 c. A Syntax Error Line 6 d. A Logical Error Line 6 e. The possibility of a Runtime Error Line 5 3

7. Put the following Systems Analysis in order. The first and last step have been done for you. [5] Present Systems Study and Analysis 2 Problem Selection and Feasibility Study 1 Implementation and Changeover Methods 5 Programming and Documentation 4 System Maintenance 7 Control and Review 6 Design of New Computerised System 3 8. Most software must be installed to disk before it can be used. a. Mention 3 things that happen during the installation process. i) The user is presented with the license agreement to accept or decline. ii) Parts of the software are copied to disk. iii) System is configured to be aware that a new program has been installed. b. Software is said to be user-friendly if it satisfies certain criteria. Mention 2 (two) such criteria. i) Easy to use, robust ii) Attractive interface, Helpful 9. Using Java syntax, write a single line statement to perform the following: a. Declare a private attribute named mark of type int. private int mark; b. Add the Scanner class declaration to a Java Class. import java.util.scanner; c. Store the result of the value of num1 and num2 into answer. answer = num1 + num2; d. Output Thanks for using the program! on screen. System.out.println( Thanks for using the program! ); 4

10. What do the following acronyms stand for? a. ATM Automated Teller Machines b. GPS Global Positioning System c. CAD Computer Aided Design d. CAL Computer Aided Learning e. POS Point of Sale 11. Work out the following: [5] Binary Decimal Hexadecimal 1 1 0 0 1 0 1 0 202 CA 10010001 145 91 217 D9 Space for working 12. The Systems Analyst has a very important role in the System Lifecycle. a. Why is a detailed systems analysis necessary during the development of a new system? To develop an efficient, easily-updatable system that caters for user s needs. b. Name two duties of the Systems Analyst. i. Draws up feasibility report. ii. Gathers data during Systems Analysis stage. c. Answer True or False i. The first step in developing a new system is the definition True of the problem. ii. Test data is supplied by the customer ordering the new system. False 5

Section B Answer BOTH questions in the space provided. 13. A local library is replacing its old computerised system with a new one. a. Name two reasons why the old system might need to be replaced. i. New functionality is needed. ii. New technology is available that can improve the system s efficiency if implemented. b. In the early stages of the development of the new system, a feasibility report is drawn up. Name two things you expect to find in such a report. i. The cost of the proposed system. ii. The time taken to develop the proposed system. c. Suggest two reasons why a client might wish to abort the project after being presented with the feasibility report. i. The system might be too expensive for his budget. ii. The timescale for developing the system might be unsuitable for the client. d. Suggest two ways in which data can be gathered during the systems analysis stage. i. Interviews with different people in the company. ii. Observation of the existent system in operation. e. After the system analysis is complete, there s a further step that needs to be taken before the coding of the new system starts. Name and briefly describe this stage. Name Description System Design System flowcharts, file formats, security measures and lists of input and output to the system are drawn up. f. Name and briefly describe two changeover methods the company may opt for. Name one advantage of each changeover method. Name Description Advantage Name Description Advantage g. With which stage of the system lifecycle would you associate the following? [4] i. The implemented system is observed in Control and review operation. ii. The client first outlines his needs to the Definition of the problem software house. iii. The user manuals are produced. Programming, testing and documentation iv. Users receive training on the new system. Implementation, training and changeover [6] 6

14. This question is about the Java programming language. a. Match [5] i. Java is A. A symbolic name in a program associated with a changeable value. ii. An object is B. A collection of statements grouped together to perform an operation. iii. A method is C. an object-oriented programming language. iv. A variable is D. A blueprint for one or many objects. v. An application is E. An instance of a class. vi. A class is F. A program designed to perform a group of tasks. i. ii. iii. iv. v. vi. C E B A F D b. A zoo is expecting new-born giant pandas soon, as one of their pandas is having young. New-born giant pandas are just around 100g but, if they are healthy, they gain weight very rapidly after birth. The zoo plans to monitor the baby pandas weight carefully for the first months of their lives. An application is being created to help the zoo monitor the pandas weight gain. One of the classes in this application is called Panda. i. The class Panda has a property called weightatbirth that stores the weight (in kg) of the panda at birth. Show how this property would be declared in Java. double weightatbirth; [Accept also float. Do not accept int, byte etc] ii. The class Panda also has a property called ageindays that stores the age of a panda in days. Show how this property would be declared in Java. int ageindays; [Accept all integer data types] ii. Write Java code to create an object of class Panda called panda1. Panda panda1 = new Panda(); iii. Method weighin() asks the user to enter the age and weight of a given panda and then outputs the weight gained to date. Write method weighin(). Assume that classes needed for this method, if any, are already imported. Relevant objects of this/these classes (if any) are to be declared in method weighin() 1 mark for correct calculation 1 mark for correct output 1 mark for input from keyboard 1 mark for overall functionality iv. Write Java code to call method weighin() for your object panda1. panda1.weighin(); [1 for partially correct answer] v. After thirty days the panda should weigh around 2kg. Write method isprogressok() that returns false if a panda s weight is less than 1.8kg and otherwise returns true. 1 mark for correct method declaration 1 mark for implementation of decision structure 1 mark for correct decision 1 mark for return of correct value 1 mark for overall functionality 7 [4] [5]

8