CS 159 FINAL

0.0(0)
Studied by 0 people
call kaiCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/106

encourage image

There's no tags or description

Looks like no tags are added yet.

Last updated 1:33 AM on 4/29/24
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai

No analytics yet

Send a link to your students to track their progress

107 Terms

1
New cards

T/F: All functions that utilize passing parameters by address must be void.

F

2
New cards

T/F: Data sent from the calling function to the function being called will be received in the same order in which it was passes.

T

3
New cards

T/F: The number of parameters cannot be determined from the declaration of a function.

F

4
New cards

Does fetching data access computer memory?

Yes

5
New cards

Does writing data access computer memory?

Yes

6
New cards

Does processing data access computer memory?

No

7
New cards

COURSE STANDARD? The declaration section and execution sections of a user- defined function must never overlap.

Yes

8
New cards

COURSE STANDARD? Attempt to minimize your use of literal constants and maximize your use of symbolic constants.

Yes

9
New cards

COURSE STANDARD? Place a single space between all operators and operands.

Yes

10
New cards

T/F: A structure chart should be more horizontal and less vertical because the main function should make a majority of the user- defined function calls.

F

11
New cards

T/F: Functions from standard C libraries such as math.h and stdio.h are not included on a structure chart.

F

12
New cards

T/F: It is possible to determine from a structure chart the order in which use-defined functions are called in a program.

F

13
New cards

T/F: Symbolic/ defined constants do not have a data type, but the values they represent do.

T

14
New cards

T/F: The assignment operator is not used to associate a value with an identifier as no memory is requires for symbolic/ defined constant.

T

15
New cards

T/F: No terminal semicolon is used when defining a symbolic/ defined constant as the define instruction is a pre-processor directive.

T

16
New cards

T/F: A mixed type expression will require at least one type conversion before the expression can be evaluated.

T

17
New cards

T/F: Only implicit type conversions can be used to change a mixed type expression to a single type expression.

F

18
New cards

T/F: An explicit type conversion cannot be applied to a symbolic/defined constant because such a constant does not have a data type.

F

19
New cards

T/F: It takes less time to access those levels of memory that are lower on the hierarchy than those that are higher.

F

20
New cards

T/F: The capacity of those levels of memory that are lower on the hierarchy is greater than those that are higher.

F

21
New cards

T/F: The memory at lower levels on the hierarchy are closer to the CPU than those that are higher.

F

22
New cards

T/F: An error related to a floating exception or segmentation fault can be detected by the compiler.

F

23
New cards

T/F: A logical error cannot be detected by the compiler.

T

24
New cards

T/F: A warning issued by the compiler will not prevent the creation of a new executable file.

T

25
New cards

T/F: A user defined function can return at most one value.

T

26
New cards

T/F: Control of a program is always returned from the called function to the calling function when the called function terminated.

T

27
New cards

T/F: One user defined function cannot call another user defined function.

F

28
New cards

T/F: The user defined functions will be declared with a local scope in your programs.

F

29
New cards

T/F: According to course standards a variable will never be permitted to define with a global scope.

T

30
New cards

T/F: It is not possible to reuse an identifier when the two objects that will share the identifier do not have an overlapping scope.

F

31
New cards

DEFINITON: Functionally cohesive

Called function accomplished only a single task in the program.

32
New cards

T/F: It is not possible to use a single scanf statement to accept input for multiple variables.

F

33
New cards

T/F: It is not possible to format output with left-alignment when using a printf.

F

34
New cards

T/F: It is not possible to write a scanf statement that does not make use of its address list

T

35
New cards

T/F: The parameter of the feof function is a file handle variable.

T

36
New cards

T/F: The value returned from the fopen function is used to initialize a file handle variable.

T

37
New cards

T/F: The name of the external file is tha parameter to the fclose function.

F

38
New cards

T/F: When the file handle variable stores a file ID value equal to -1 it means the external file failed to open as expected.

T

39
New cards

T/F: The value returned from the fscanf function is the data value that was read from the external file.

T

40
New cards

T/F: The feof function will return a zero when the end of the file has been reached.

F

41
New cards

Why is the "gets" function considered to be dangerous to the compiler?

The input of the user may exceed the defined size of the array.

42
New cards

T/F: A warning issued by the compiler will not prevent the creation of a new file executable.

T

43
New cards

T/F: An error in the logic of the program cannot be detected by the compiler.

T

44
New cards

T/F: An segmentation fault can be detected by the compiler.

F

45
New cards

T/F: A structure chart should be more horizontal and less vertical because the main function should make a majority of the user- defined function calls.

T

46
New cards

T/F: Functions from standard C libraries such as math.h and stdio.h are not included on a structure chart.

T

47
New cards

T/F: It is impossible to determine from a structure chart the order in which user-defined functions are called in a program.

F

48
New cards

T/F: Symbolic/ defined constants don’t have a data type, but the values that they represent do.

T

49
New cards

T/F: The assignment operator is not used to associate a value with an identifier as no memory is required for a symbolic/ defined constant.

T

50
New cards

T/F: No terminal semicolon is used when defining a symbolic/ defined constant as the define instruction is a pre-processor directive.

T

51
New cards

T/F: No two case labels can represent the same constant value.

T

52
New cards

T/F: Each case label is the keyword case followed by a constant expression.

T

53
New cards

T/F: Only a single executable statement can be associated with any given case.

F

54
New cards

T/F: The user defined functions will be declared with in the local declaration section in your programs this semester.

F

55
New cards

T/F: According to course standards a variable will be permitted to be defined with a global scope.

F

56
New cards

T/F: It is possible to reuse an identifier when the two objects that will share the identifier do not have an over lapping scope.

T

57
New cards

T/F: The number of times the loop control expression is evaluated equals the number of iterations in a post- test loop.

T

58
New cards

T/F: The initialization of the loop control variable may take place inside of the body in a post test loop.

T

59
New cards

T/F: The update action for the loop control variable may be a part of the loop control expression.

T

60
New cards

T/F: The short circuit methon is applied onlt to logical expression in if/else if conditions.

F

61
New cards

T/F: The short circuit method is not applied to logical operators used as loop control expressions.

F

62
New cards

T/F: The short circuit method is applied to all logical expressions that use a logical operator.

T

63
New cards

T/F: The function definition requires the data types and identifiers for each parameter

F

64
New cards

T/F: The function call requires the data types and identifiers for each parameter.

F

65
New cards

T/F: The first line of the function definition requires the data types and identifiers for each parameter.

T

66
New cards

T/F: A user defined function should not be designed such that it completes multiple tasks in a program.

T

67
New cards

T/F: The use of a user defined function should eliminate the need for the same logic to appear in more than one location of a program.

T

68
New cards

T/F: Each user defined function should be testable apart from the rest of the program.

T

69
New cards

T/F: The control of the program always returns from the calling function to the main function.

F

70
New cards

T/F: Data sent from the calling function to the function being called will be received in the same order which it was passed.

T

71
New cards

T/F: The return statement cannot contain an expression.

F

72
New cards

T/F: Both implicit type conversions and assignment conversions in an expression will not result in a loss of data as a result of the conversion.

F

73
New cards

T/F: When evaluating a mathematical operator with operands of different types it is the lower ranked data type that is converted to that of the higher data type.

T

74
New cards

T/F: Converting a higher ranked data type to that of a lower ranked data type may result in the loss of data.

T

75
New cards

T/F: A symbolic/ defined constant may be created anywhere in the program.

F

76
New cards

T/F: Within each function the local declarations and executable statements must never be permitted to overlap.

F

77
New cards

T/F: Variable and function declarations will never be permitted in the global section this semester.

F

78
New cards

T/F: The flag attribute of a placeholder within the format string of a printf statement can be used to shift the alignment from right to left when making use of a width modifier.

T

79
New cards

T/F: The width and precision modifier attributes of a placeholder within the format string of a printf statement cannot be represented by variables and must always be constant values.

F

80
New cards

T/F: The precision modifier when used in the format string of a printf statement can specify the number of digits to display on both sides of the decimal point of a floating point value.

F

81
New cards

T/F: The order in which the function definitions appear in a program must match the order in which they are declared.

F

82
New cards

T/F: The order in which the function declarations appear in a program must match the order in which they are defined.

F

83
New cards

T/F: The order in which function definitions appear must match the order in which they are called.

F

84
New cards

Which classification of languages was developed to be independent of the specific of hardware of which it may be used?

High-level programming languages

85
New cards

T/F: The return type of any function that makes use of passing parameters must be void.

F

86
New cards

T/F: When passing multiple parameters to a function if one parameter is to be passed by address then all of the parameters should be passed by address.

F

87
New cards

T/F: Use of parameter passing by address permits multiple tasks of a programming problem to be consolidated into a single -user defined function

F

88
New cards

T/F: The short circuit method of evaluating logical expressions is limited only to those logical expressions used in selection constructs.

F

89
New cards

T/F: The short circuit method of evaluating logical expressions is limited to only those logical expressions used in repetition constructs.

F

90
New cards

T/F: The short circuit method of evaluating logical expressions is limited only to those logical expressions used in assignment operators.

F

91
New cards

T/F: The use of { and } with if/else constructs is options when not required by the compiler.

F

92
New cards

T/F: All code found inside of the body of if/else constructs must be indented two additional spaces.

T

93
New cards

T/F: The body of any if, else it, or else should never remain empty.

T

94
New cards

T/F: The use of recursion should be limited to counter-controlled processes.

T

95
New cards

T/F: The use of the for loop should be limited to counter-controlled processes.

T

96
New cards

T/F: The use of the do while loop should be limited to event-controlled processes.

F

97
New cards

T/F: When the base case is reached the control of the program will immediately return to main.

F

98
New cards

T/F: An infinite number of recursive function calls will result in an identical behavior of an infinite loop.

T

99
New cards

T/F: The return type of a recursive function may be void.

T

100
New cards

T/F: Two case statements cannot represent the same constant value.

T

Explore top notes

note
Unit 6: Period 6: 1865–1898
Updated 78d ago
0.0(0)
note
Chapter 12: Colons and Dashes
Updated 1017d ago
0.0(0)
note
Chapter 15: Writing Systems
Updated 1280d ago
0.0(0)
note
Physics by Holt- Chapter 1 notes
Updated 1291d ago
0.0(0)
note
What is Theatre?
Updated 1364d ago
0.0(0)
note
Biology 1 - Mod 3 Cell Discovery
Updated 1210d ago
0.0(0)
note
history test 1 summary
Updated 1037d ago
0.0(0)
note
Chapter 13 - The Reform Impulse
Updated 1280d ago
0.0(0)
note
Unit 6: Period 6: 1865–1898
Updated 78d ago
0.0(0)
note
Chapter 12: Colons and Dashes
Updated 1017d ago
0.0(0)
note
Chapter 15: Writing Systems
Updated 1280d ago
0.0(0)
note
Physics by Holt- Chapter 1 notes
Updated 1291d ago
0.0(0)
note
What is Theatre?
Updated 1364d ago
0.0(0)
note
Biology 1 - Mod 3 Cell Discovery
Updated 1210d ago
0.0(0)
note
history test 1 summary
Updated 1037d ago
0.0(0)
note
Chapter 13 - The Reform Impulse
Updated 1280d ago
0.0(0)

Explore top flashcards

flashcards
GenOmgevingssamenspel
37
Updated 1060d ago
0.0(0)
flashcards
WIP 117
20
Updated 1164d ago
0.0(0)
flashcards
spanish foods
60
Updated 1079d ago
0.0(0)
flashcards
Hist 106 Exam 1 Study Guide
70
Updated 189d ago
0.0(0)
flashcards
Brain Bee
177
Updated 1185d ago
0.0(0)
flashcards
GenOmgevingssamenspel
37
Updated 1060d ago
0.0(0)
flashcards
WIP 117
20
Updated 1164d ago
0.0(0)
flashcards
spanish foods
60
Updated 1079d ago
0.0(0)
flashcards
Hist 106 Exam 1 Study Guide
70
Updated 189d ago
0.0(0)
flashcards
Brain Bee
177
Updated 1185d ago
0.0(0)