This paper concentrates on the primary theme of Write part of a program to print a calendar for the years 2016 to 2036 with one line per year. The following array (M) is ALREADY held in memory showing the number of days in each month – February (*) will need adjusting upwards for leap years. in which you have to explain and evaluate its intricate aspects in detail. In addition to this, this paper has been reviewed and purchased by most of the students hence; it has been rated 4.8 points on the scale of 5 points. Besides, the price of this paper starts from £ 40. For more details and full access to the paper, please refer to the site.
Instructions to candidates:
allowed: Three hours (plus an extra ten minutes’ reading time at the start – do
not write anything during this time)
Answer ALL parts of Question 1 (40 marks) and any FOUR other questions (15
Marks for subsections of questions are shown in [ ]
Spend about 1 hour on Question 1 and just under 30 minutes on each other
question. Read CAREFULLY the particular instructions for Question 1
State at the top of your answer FOR EACH QUESTION, where appropriate, the
programming language and version you are using for that question. Different
languages may be used
Ensure that you pay particular attention to words underlined, in CAPITALS or in
bold. FEW OR NO
will be awarded to any question where these are ignored
computer equipment, books or notes may be used in this examination
instructions for QUESTION 1: Answer all parts of this question.
Provide high-level language solutions to each question in this section
Do NOT provide any coding for anything outside the question – complete
programs are NOT required
Do not change the names of variables/file names in your answers
Data only needs to be input into variables where the question
specifically states ‘INPUT’
Any additional temporary variables YOU introduce must have clear
meaningful names and be assigned with initial values
1.a) A useful calendar covering MANY years can be printed on a single page if only the first day of each month is displayed, e.g.
FIRST OF THE MONTH
So if it is known that April 1st 2016 is on a Friday, the other dates in April can be worked out fairly easily. Write part of a program to print a calendar for the years 2016 to 2036 with one line per year. The following array (M) is ALREADY held in memory showing the number of days in each month – February (*) will need adjusting upwards for leap years.
Use a NUMERIC value for day. DAY = 0 for SUNDAY, DAY = 1 for MONDAY through to
DAY = 6
for SATURDAY. Decide on your loops first. 
Write a program that will prompt for input of a series of integers (stored in
variable intNum). Count the integers as they are entered and store this value
in variable intCount. Keep track of the accumulative total (intTotal).
program ends when intTotal is greater than or equal to 100.
final input takes intTotal over 100, do not include this in the total and
decrease the value of
Finally display the value of intCount. 
Colours are symbolised by their initial letter. In this problem, only THREE
colours are involved, RED (R), BLUE (B) and GREEN (G).
the symbols for TWO colours. Check that the colours are different before
proceeding – re-input if necessary. Then, determine the third colour and output
its code. So if ‘R’ and ‘G’ are input, ‘B’ will be output. 
2.Draw up an algorithm (pseudo-code or flowchart) to perform the following task:
Input a decimal integer and convert it to binary using the standard manual method described below. This method shows conversion of decimal 22 but your algorithm must work for ANY decimal integer.
Method – divide number repeatedly by 2 and store the remainder at each stage. The process stops when the number is reduced to zero. The remainders are then output in REVERSE order so you will need an array (or alternative structure) to hold each remainder at each stage.
2 ) 22
2 ) 11
so decimal 22 = 10110
3.The following algorithm calculates discounts on customer accounts. Line numbers have been included to help you.
a)Perform a dry run on this routine then answer the questions that follow:
T1 = 0
T2 = 0
Do while R <> “z”
If R = “y” then
D = A * 15/100
D = A * 10/100
Print N, A, D
T1 = T1 + A
T2 = T2 + D
Print “Totals”, T1, T2
“Artworld ltd”, “x”, 1470, “Abc co.”, “y”, 300, “DesignCo” , “y”, 5000, “CopyPlus”, “x”, 550, “z”, “z”, 0
Which data item will cause the loop to exit? 
discount for “x” accounts is to change to 12.5% and for “y” accounts 20%. What
changes need to be made in the program? 
effect, if any, would there be on the final output if “q” was mistakenly
entered instead of “x” for the 4th input record? 
The following five points are factors to consider when writing a program in a high-level language.
time to develop the
logic and coding
program statements in the source code
The time it takes to compile the program
run time of the
size of memory to hold
the compiled program
each of these factors to the same
program being written in a low-level language. For
factor state whether the value would be higher, lower or the same for the
EACH of your answers. 
Outline the main stages of the compilation process. 
Discuss the differences between object oriented programming and procedural
a procedural programming language and an object oriented programming language
and describe an application or program that each would be best suited for. 
Explain what the term event-driven means in programming, give an example. 
Explain why documentation is a necessary part of program development. 
Describe THREE different people that would need program documentation. For EACH
person, explain what aspects of the documentation they would require and
outline the reasons why they would need it. 
of the following is an error or an error message that might occur during
development of a program.
whether it occurs at RUN-TIME or during COMPILATION
explain HOW the error can be corrected so that it does not occur when an
IDENTICAL run is performed immediately afterwards
DIVISION BY ZERO
Incorrect final totals on an invoice
PRINT is used as a variable name [3 each]
Outline THREE different program
design tools. For EACH, describe their purpose, discuss the advantages and
illustrate an example.
Note – the advantages
should be different for each method described. [5 each]