Professional Documents
Culture Documents
Structure Charts-WS
Structure Charts-WS
Name:___________________ Date:_________________
1 The structure chart shows part of the design of a program for an online shopping system.
Process basket
B
A E
C F
D
G
(ii) The parameters A to G shown on the chart will be used to pass the following information.
PaymentDetails
Quantity
BasketID
DeliveryAddress
ItemID
Complete the following table to show the parameter and the information it represents.
Parameter Information
D
9608/22/M/J/18
E
G [3]
1
2 (a) A structure chart is a tool used in modular program design.
State three pieces of information that a structure chart can convey about a program design.
1 ................................................................................................................................................
...................................................................................................................................................
2 ................................................................................................................................................
...................................................................................................................................................
3 ................................................................................................................................................
...................................................................................................................................................
[3]
Checkout
B A
Card Account
payment payment
Examples of the data items that correspond to the arrows are given in this table:
Use pseudocode to write the function header for the Card payment module.
...................................................................................................................................................
...............................................................................................................................................[3]
9608/21/M/J/17
2
3 To code the ‘Search by product code’ procedure, Ahmed draws a structure chart showing the
different stages.
You can assume that before the procedure is run, all the product data is read from file
PRODUCTS and then stored in three 1D arrays as described in part (c)(i).
Lookup by
product code
......................
......................
......................
.................
................ ......................
......................
[4]
9608/21/O/N/16
3
4 (a) Structured programming involves the breaking down of a problem into modules.
1 ................................................................................................................................................
...................................................................................................................................................
2 ................................................................................................................................................
...................................................................................................................................................
[2]
(b) A team needs to write a program to implement an online shopping system. Customers will
access the program via a website.
Customers can search for items before adding them to a virtual shopping basket. When they
have finished shopping, they pay for the items. The program provides output for the dispatch
of the items.
(i) Draw on the chart, the symbols that represent the key features listed in part (b) above.
Online shopping
4
A section of the chart in part (b)(i) is shown below. It is to show the parameters passed
between the Checkout and Card payment modules.
Checkout
B A
Card Account
payment payment
[3]
5
5 (a) Name two features of your chosen high-level programming language that support the
implementation of a modular design.
1 ................................................................................................................................................
2 ................................................................................................................................................
[2]
(b) (i) The structure chart shows part of the design of a program for an online shopping system.
The user has already added a number of products to their virtual basket.
Draw on the chart, the symbol to show that the process of modifying the basket contents
may be iterated (repeated).
E
A F
C
[1]
The table below shows the three data items that the six parameters pass between
modules.
Parameter
Data item
A B C D E F
Product ID
Quantity
Flag Value – indicating
operation success or fail
[4]
9608/23/M/J/16