The pseudocode shown below uses a simple condition.
IF age < 5 THEN SEND nursery TO DISPLAY
Create a complex condition that will display “school” if a person is between the ages of 5 and 18 inclusive. (2)
The pseudocode shown below uses a simple condition.
IF age < 5 THEN SEND nursery TO DISPLAY
Create a complex condition that will display “school” if a person is between the ages of 5 and 18 inclusive. (2)
A programming language provides the following pre-defined functions.
move(n) = distance moved in pixels
rotate(d) = degrees turned (positive means clockwise)
These can be used by the programmer to draw lines.
A programmer writes the code to draw a square. The code is shown below.
Write the code that would draw a hexagon. (3)
Jack has been asked to write a program to calculate the potential profit in a soft drinks business. The program will store the costs involved in producing and selling one litre of each drink.
The following calculations will be used to output the profit made for each litre of drink.
Manufacturing Cost = Water Cost + Flavouring Cost + Labour Cost
Profit = Selling Cost – Manufacturing Cost
Using pseudocode or a programming language of your choice, write a program to enter the required data, then calculate and display the profit for the soft drink business. (5)
Glow Blogs uses cookies to enhance your experience on our service. By using this service or closing this message you consent to our use of those cookies. Please read our Cookie Policy.