Midterm (Chapters 1-5) Flashcards
A ______ Is a set of instructions that a computer will follow to perform a task.
Program
The term hardware refers to
All the physical devices that make up a computer
The CPU (Central Processing Unit) is the part of the computer that
actually runs programs and is the most important component in a computer
How does a disk drive store data
Magnetically by encoding it onto a circular disk
What are microprocessors
Small central processing unit chips
What is the type of memory that can hold data for a long period of time? EVEN if there is no power to the computer
Secondary storage
Main Memory is known as
RAM
How do USB drives store data
Using flash memory
Is python an interpreter or compiler?
Python is an interpreter that can read python programming statements and execute them
In which mode does the interpreter read the contents of a file that contains python statements and executes each statement?
Script mode
What is the output of the following statement?
print(‘I\’m ready to begin’)
I’m ready to begin
What is the output of the following statement, given that value1 = 2.0 and value 2 = 12?
print(value1*value2)
24.0
What is the output of the following statement?
print(‘The path is D:\sample\test.’)
The path is D:\sample\test.
What are the notes of explanation that document lines or sections of a program?
Comments
What symbol is the remainder operator? What is it also known as?
%, it is also known as the modulus (mod) operator
What character is a special character that is preceded with a backslash (), appearing inside a string literal?
An escape character
What specifier is a special set of characters that specify how a value should be formatted?
The formatting specifier.
When applying what formatting specifier to the number 76.15854 will it result in 76.159?
the .3f formatting specifier
What is a software requirement?
a single task that the program must perform in order to satisfy the customer.
In the expression 12.45 + 3.6 the values to the right and left of the + symbol are what?
They are the operands