Post by scythe123 on Aug 21, 2024 13:02:59 GMT 10
page 188
1) Variables are used to store data so they can be retrieved and changed in a program while instructions are a unit of code that can be executed by a compiler or interpreter.
2)
a. seekAlternativeRoute()
b. False
c. potato
d. user.firstName
e. 2019
f. isValid
g. “chocolate”
3)
a. Definition
b. Statement
c. Definition
4) Sequences, conditions, iterations
5) Sequences are sets of instructions that execute line by line; every line of code is run in the order in which it is written, while iterations repeat sections of code multiple times until a condition is met.
6) Pirru could have used a WHILE or function loop.
7)
a. True
b. Experienced
8) They’re represented in bold and all capitals.
9) A function declarations name functions and its arguments, whilst function definitions outline the contents of a function.
10) Classes allow programmers to group together related functions and variables in one place, creating a template for objects. Objects on the other hand allow programmers to manipulate data.
11) Methods are functions that exist within classes. Events are a special type of method that is called when an object’s state changes.
12)
ALGORITHM usemethod()
begin
mathobj = create new object from math class
mathobj.addTwoNumbers (4,1)
END
13) It explains and provides important context on how the code functions to not only the programmer but also a third party who may be reviewing the program.
14) Name of the file, its purpose, the author’s name and the date of creation.
15) # is used to indicate a single line comment in Python.
16) Text files store data as easily readable plain text, whereas binary files store data in binary form, as in the case of images and sound.
17) Reading, writing, opening and closing.
18) Plain text files are structured files containing characters of readable data; they are commonly used for configuration settings or storing small amounts of data.
19) Delimited files are particular types of text files that are structured using delimiter-separated values.
20) A type of delimited file in which fields are separated by commas.
21) XML files are easier to read for humans and always abides by a certain set of conventions and rules.
22) Root – The first element in an XML tree, and parent to all other elements. There can only be one root element. In Figure 4.27, this is represented by the element.
Parent – Any element that contains sub-elements. An example in Figure 4.27 is the element.
Child – Any sub-element to another element. An example in Figure 4.27 is the element.
23) Test cases are a set of steps that a tester uses to determine if the element being tested works correctly, often outlining test data, testing procedures, and expected results. Test data on the other hand is data that has been specifically identified to be used in a test case.
24) Syntax errors are errors, often typographical, in source code that violates the set of rules that define a programming language while runtime errors are errors that occur while a program is running.
25) To prevent logic errors from occurring within the code and to validate the logic and algorithms contained in the source code.
26) Boundary values are the minimum and maximum values available for a given input.
27) Test data that focuses on boundary values tests the restraints of the program and ensures all values between the boundary values will work as inputs.
28) They accurately simulate the execution of a program going through the code step by step.
Errors with logic or any algorithms within the code can be clearly spotted out in a trace table as we are debugging one step at a time.
29)
30)
a. Determine how well the solution meets the requirements outlined.
b. Test the efficiency of the program, specifically:
i. Speed or processing
ii. Functionality of software
iii. Cost of file manipulation
c. Test the effectiveness of the program, specifically:
i. Completeness
ii. Readability
iii. Attractiveness
iv. Clarity
v. Functionality
vi. Accuracy
vii. Accessibility
viii. Timeliness
ix. Report formats
x. Relevance
xi. Usability
xii. Communication of message
31) An evaluation strategy specifies the timeframe in which an evaluation will occur and outlines the data that will need to be collected to complete the evaluation, including a description of the methods and techniques that will be used to collect that data. The strategy also makes clear how the data collected relates to the criteria that were written in the design stage.
32) Effectiveness of a solution relates to how well a solution achieves its intended results; this is measured against completeness, readability, attractiveness, clarity, functionality, accuracy, accessibility, timeliness, report formats, relevance, usability and communication of message.
33) Efficiency of a solution concerns how much time, cost and effort has been applied to achieve the intended results; this is measured against speed of processing, functionality of the software or cost of file manipulation.
1) Variables are used to store data so they can be retrieved and changed in a program while instructions are a unit of code that can be executed by a compiler or interpreter.
2)
a. seekAlternativeRoute()
b. False
c. potato
d. user.firstName
e. 2019
f. isValid
g. “chocolate”
3)
a. Definition
b. Statement
c. Definition
4) Sequences, conditions, iterations
5) Sequences are sets of instructions that execute line by line; every line of code is run in the order in which it is written, while iterations repeat sections of code multiple times until a condition is met.
6) Pirru could have used a WHILE or function loop.
7)
a. True
b. Experienced
8) They’re represented in bold and all capitals.
9) A function declarations name functions and its arguments, whilst function definitions outline the contents of a function.
10) Classes allow programmers to group together related functions and variables in one place, creating a template for objects. Objects on the other hand allow programmers to manipulate data.
11) Methods are functions that exist within classes. Events are a special type of method that is called when an object’s state changes.
12)
ALGORITHM usemethod()
begin
mathobj = create new object from math class
mathobj.addTwoNumbers (4,1)
END
13) It explains and provides important context on how the code functions to not only the programmer but also a third party who may be reviewing the program.
14) Name of the file, its purpose, the author’s name and the date of creation.
15) # is used to indicate a single line comment in Python.
16) Text files store data as easily readable plain text, whereas binary files store data in binary form, as in the case of images and sound.
17) Reading, writing, opening and closing.
18) Plain text files are structured files containing characters of readable data; they are commonly used for configuration settings or storing small amounts of data.
19) Delimited files are particular types of text files that are structured using delimiter-separated values.
20) A type of delimited file in which fields are separated by commas.
21) XML files are easier to read for humans and always abides by a certain set of conventions and rules.
22) Root – The first element in an XML tree, and parent to all other elements. There can only be one root element. In Figure 4.27, this is represented by the element.
Parent – Any element that contains sub-elements. An example in Figure 4.27 is the element.
Child – Any sub-element to another element. An example in Figure 4.27 is the element.
23) Test cases are a set of steps that a tester uses to determine if the element being tested works correctly, often outlining test data, testing procedures, and expected results. Test data on the other hand is data that has been specifically identified to be used in a test case.
24) Syntax errors are errors, often typographical, in source code that violates the set of rules that define a programming language while runtime errors are errors that occur while a program is running.
25) To prevent logic errors from occurring within the code and to validate the logic and algorithms contained in the source code.
26) Boundary values are the minimum and maximum values available for a given input.
27) Test data that focuses on boundary values tests the restraints of the program and ensures all values between the boundary values will work as inputs.
28) They accurately simulate the execution of a program going through the code step by step.
Errors with logic or any algorithms within the code can be clearly spotted out in a trace table as we are debugging one step at a time.
29)
step | statement | x | y | output |
1 | x ~ 7 | 7 | | |
2 | y ~ 1 | 7 | 1 | |
3 | WHILE y < x DO | 7 | 1 | |
4 | y ~ x * y | 7 | 7 | |
5 | x ~ x + x | 14 | 7 | |
6 | WHILE y < x DO | 14 | 7 | |
7 | y ~ x * y | 14 | 98 | |
8 | x ~ x + x | 28 | 98 | |
9 | ENDWHILE | 28 | 98 | |
10 | PRINT x, y | 28 | 98 | 28, 98 |
30)
a. Determine how well the solution meets the requirements outlined.
b. Test the efficiency of the program, specifically:
i. Speed or processing
ii. Functionality of software
iii. Cost of file manipulation
c. Test the effectiveness of the program, specifically:
i. Completeness
ii. Readability
iii. Attractiveness
iv. Clarity
v. Functionality
vi. Accuracy
vii. Accessibility
viii. Timeliness
ix. Report formats
x. Relevance
xi. Usability
xii. Communication of message
31) An evaluation strategy specifies the timeframe in which an evaluation will occur and outlines the data that will need to be collected to complete the evaluation, including a description of the methods and techniques that will be used to collect that data. The strategy also makes clear how the data collected relates to the criteria that were written in the design stage.
32) Effectiveness of a solution relates to how well a solution achieves its intended results; this is measured against completeness, readability, attractiveness, clarity, functionality, accuracy, accessibility, timeliness, report formats, relevance, usability and communication of message.
33) Efficiency of a solution concerns how much time, cost and effort has been applied to achieve the intended results; this is measured against speed of processing, functionality of the software or cost of file manipulation.