CMPSC 200 FINAL EXAM PSU
QUESTIONS AND ANSWERS 100% PASS
2026/2027
Computer - ANS a programmable electronic device that can store, retrieve, and process data
input - ANS data from the user is entered into the computer
Processing - ANS the computer is instructed what to do you the program, often using
information that was input to the program
Output - ANS input inputted or processed through the program is output to the user
High-level computer architecture - ANS the main memory stores programs and program data
in random access memory (RAM)
CPU - ANS central processing unit
CPU has two main components - ANS arithmetic and logic unit (ALU) - mathematical
operations
@2026 ALLRIGHTS RESERVED 1
,control unit - fetches the next instruction, decodes the instruction, and then executes the
instruction as appropriate
Volatile memory - ANS temporary storage, information is lost when the power to the
memory is lost. typically faster or higher performing than non-volatile memory
ex: RAM, DRAM (dynamic ram)
Non-volatile memory - ANS permanent storage, information persists even after power is lost.
typically slower than volatile memory
ex: read-only memory (ROM), compact discs (CD), magnetic tape
Program - ANS a set of instructions to perform specific tasks
Algorithm - ANS a set step for "doing something"
Operating systems - ANS allocated computer resources and allows communication between
the user and the computer
High-level languages - ANS easy for humans to understand, but too difficult for a computer to
understand
Low-level languages - ANS harder for humans to understand, but easier for a computer to
convert to usable instructions
Machine language - ANS generally quite difficult for humans to understand, the binary digits
that contain instructions that can be understood by the computer
@2026 ALLRIGHTS RESERVED 2
,Compiled - ANS code written by the programmer is reduced to a set of machine-specific
instructions prior to runtime. these instructions are saved as executable files, which can be run
MATLAB stands for - ANS Matrix laboratory
Three phases of program writing - ANS Analyze, implement, maintain the code
Analyze - ANS - specify what the program needs to do
- develop the algorithm(s) to solve your problem
- verify that what you have will work
Implement - ANS - code the program
- test the program
Maintain the code - ANS for large or long-term software systems, this can be the most
expensive part
Constant - ANS a variable whose value is not intended to change
Create script - ANS - where we are going to store commands
- they do not execute they are simply stored
- working in a script allows you to save your work
clc - ANS clear the command window
clear - ANS delete all the variables from the workspace
@2026 ALLRIGHTS RESERVED 3
, To delete specific variables type - ANS clear(variable)
Block comment - ANS %{..........%}
- must put writing on the next line from the first percent
By doing .* it gives you - ANS an element by element operation
A variable can - ANS contain multiple pieces of information
abs(data#) - ANS absolute value
sqrt(#) - ANS square root
nthroot(#,#) - ANS nth root (x,n)
sign(#) - ANS signum function
- if the input is positive MATLAB will return the number +1
- if the input is negative MATLAB will return the number -1
- if the input is zero MATLAB will return the number 0
rem(x,y) - ANS remainder of x divided by y
exp(x) - ANS e^x
@2026 ALLRIGHTS RESERVED 4
QUESTIONS AND ANSWERS 100% PASS
2026/2027
Computer - ANS a programmable electronic device that can store, retrieve, and process data
input - ANS data from the user is entered into the computer
Processing - ANS the computer is instructed what to do you the program, often using
information that was input to the program
Output - ANS input inputted or processed through the program is output to the user
High-level computer architecture - ANS the main memory stores programs and program data
in random access memory (RAM)
CPU - ANS central processing unit
CPU has two main components - ANS arithmetic and logic unit (ALU) - mathematical
operations
@2026 ALLRIGHTS RESERVED 1
,control unit - fetches the next instruction, decodes the instruction, and then executes the
instruction as appropriate
Volatile memory - ANS temporary storage, information is lost when the power to the
memory is lost. typically faster or higher performing than non-volatile memory
ex: RAM, DRAM (dynamic ram)
Non-volatile memory - ANS permanent storage, information persists even after power is lost.
typically slower than volatile memory
ex: read-only memory (ROM), compact discs (CD), magnetic tape
Program - ANS a set of instructions to perform specific tasks
Algorithm - ANS a set step for "doing something"
Operating systems - ANS allocated computer resources and allows communication between
the user and the computer
High-level languages - ANS easy for humans to understand, but too difficult for a computer to
understand
Low-level languages - ANS harder for humans to understand, but easier for a computer to
convert to usable instructions
Machine language - ANS generally quite difficult for humans to understand, the binary digits
that contain instructions that can be understood by the computer
@2026 ALLRIGHTS RESERVED 2
,Compiled - ANS code written by the programmer is reduced to a set of machine-specific
instructions prior to runtime. these instructions are saved as executable files, which can be run
MATLAB stands for - ANS Matrix laboratory
Three phases of program writing - ANS Analyze, implement, maintain the code
Analyze - ANS - specify what the program needs to do
- develop the algorithm(s) to solve your problem
- verify that what you have will work
Implement - ANS - code the program
- test the program
Maintain the code - ANS for large or long-term software systems, this can be the most
expensive part
Constant - ANS a variable whose value is not intended to change
Create script - ANS - where we are going to store commands
- they do not execute they are simply stored
- working in a script allows you to save your work
clc - ANS clear the command window
clear - ANS delete all the variables from the workspace
@2026 ALLRIGHTS RESERVED 3
, To delete specific variables type - ANS clear(variable)
Block comment - ANS %{..........%}
- must put writing on the next line from the first percent
By doing .* it gives you - ANS an element by element operation
A variable can - ANS contain multiple pieces of information
abs(data#) - ANS absolute value
sqrt(#) - ANS square root
nthroot(#,#) - ANS nth root (x,n)
sign(#) - ANS signum function
- if the input is positive MATLAB will return the number +1
- if the input is negative MATLAB will return the number -1
- if the input is zero MATLAB will return the number 0
rem(x,y) - ANS remainder of x divided by y
exp(x) - ANS e^x
@2026 ALLRIGHTS RESERVED 4