7. Algorithm Design and Problem-Solving Flashcards

1
Q

Analysis

A

identify the problem and its requirements

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Design

A

develop an algorithm to solve the problem by using structure diagrams, flowcharts or pseudocode

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Coding

A

write and implement the instructions to solve the problem

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Testing

A

detect and fix the errors in the program

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Sub-systems of a computer

A
  • CPU
  • memory
  • storage
  • input devices
  • output devices
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Component parts after a problem has been decomposed

A
  • inputs
  • processes
  • outputs
  • storage
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Methods to design and construct a solution to a problem

A
  • structure diagrams
  • flowcharts
  • pseudocode
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Standard methods of solution

A
  • linear search
  • bubble sort
  • totalling
  • counting
  • finding maximum, minimum and average values
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Features that should be included to create a maintainable program

A
  • meaningful identifiers…
  • …to enable to programmer to easily recognise the purpose
  • …of variables, constants, arrays, procedures etc.
  • …by example
  • use of comments…
  • …to annotate each section of a program so that a programmer can find specific sections/so the programmer knows the purpose of that section of code
  • …for example logic/syntax
  • procedures and functions…
  • …to avoid repeated code
  • …to simplify logic
  • …to make programs modular and easier to update
  • use indentation and white space…
  • …to make the program readable
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Purpose of ROUND

A
  • to return a number rounded to a specific number of decimal places
  • the result will either be rounded to the next highest or lowest value
  • …depending on whether the value of the preceding digit is >5 or <5
  • example
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Purpose of MOD

A
  • to perform (integer) division when one number is divided by another
  • …to find the remainder
  • example
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Purpose of RANDOM

A
  • to generate (pseudo) random numbers
  • …(usually) within a specific range
  • example
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Data validation

A
  • an automated check carried out by a computer
  • …to make sure the data entered is sensible/acceptable/reasonable
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Validation checks

A
  • range check
  • length check
  • type check
  • presence check
  • format check
  • check digit
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Verification checks

A
  • visual check
  • double entry check
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Why verification checks are used

A
  • to ensure that data has been accurately copied/are entered as intended
  • …from one source to another
17
Q

Validation vs verification

A
  • validation ensures that data is sensible and allowable
  • verification ensures that data entered is the same as the original/intended
18
Q

Types of test data

A
  • normal
  • abnormal
  • extreme
  • boundary
19
Q

Purpose of test data

A
  • check that the program works as expected
  • check for logic/runtime errors
  • check that the program rejects any invalid data that is input
  • check that the program only accepts reasonable data
20
Q

Purpose of using procedures

A
  • to enable the programmer to write a collection of programming statements under a single identifier
  • to allow modular programs to be created/to allow procedures to be re-used within the program or in other programs
  • to make program creation faster because procedures can be re-used/to enable different programmers to work on different procedures in the same project
  • to make programs shorter, making it easier to maintain
21
Q

Purpose of using parameters

A
  • to pass values from the main program to a procedure/function
  • …so that they can be used in the procedure/function
  • allow the procedure/function to be used with different data
22
Q

Abstraction

A
  • simplifying the problem
  • removing unnecessary details from the problem/selecting elements required
  • filtering out irrelevant characteristics from those elements
23
Q

Reasons for storing data in a file

A
  • data is stored permanently
  • data can be moved onto another computer
  • data can be used by more than one program/can be reused when a program is run again
  • another copy of the data can be made and stored/accessed elsewhere/backup copy