Chapters 1-3 "Python Programming: An
Introduction to Computer Science, 3rd
Ed." by John Zelle
A problem is intractable when ___________ - ANS-it is not practical to solve
\A statement is ____________ - ANS-a complete computer command
\An algorithm is like a _____ - ANS-recipe
\By convention, the statements of a program are often placed in a function called ______ -
ANS-main
\Computer languages designed to be used and understood by humans are _______ -
ANS-high-level languages
\Fragments of code that produce or calculate new data values are called ______ -
ANS-expressions (NOT assignment statements)
\In a mixed-type expression involving ints and (to) floats, Python will convert _____ -
ANS-ints to floats
\In modern Python, an int value that grows larger than the underlying hardware int ____ -
ANS-uses more memory
\In order to use functions in the math library, a program must include ____ - ANS-an import
statement
\In Python getting user input is done with a special expression called ____ - ANS-input
\One difference between a compiler and an interpreter is ____ - ANS-a compiler is no longer
needed after a program is translated
\T/F A chaotic function can't be computed by a computer. - ANS-FALSE we literally wrote the
chaos.py program that computes a chaotic function
\T/F A counted loop is designed to iterate a specific number of times. - ANS-TRUE
\T/F A function definition is a sequence of statements that defines a new command. -
ANS-TRUE
\T/F A hardware float can represent a larger range of values than a hardware int. -
ANS-TRUE
\T/F A loop is used to skip over a section of a program. - ANS-FALSE a loop is used to
repeat a section of code
\T/F A programming environment refers to a place where programmers work. - ANS-FALSE
a programming environment is a program designed to help programmers write programs
\T/F A Python int can represent indefinitely large numbers. - ANS-FALSE Python is limited
by the amount of computer memory available.
\T/F A variable is used to give a name to a value to it can be referred to in other places. -
ANS-TRUE
\T/F All information that a computer is currently working on is stored in main memory. -
ANS-TRUE
\T/F An algorithm can be written without using a programming language. - ANS-TRUE
\T/F Computer science is the study of computers. - ANS-FALSE the fundamental question is
"what can be computed?"
\T/F Computers represent numbers using base 2 representations. - ANS-TRUE
Introduction to Computer Science, 3rd
Ed." by John Zelle
A problem is intractable when ___________ - ANS-it is not practical to solve
\A statement is ____________ - ANS-a complete computer command
\An algorithm is like a _____ - ANS-recipe
\By convention, the statements of a program are often placed in a function called ______ -
ANS-main
\Computer languages designed to be used and understood by humans are _______ -
ANS-high-level languages
\Fragments of code that produce or calculate new data values are called ______ -
ANS-expressions (NOT assignment statements)
\In a mixed-type expression involving ints and (to) floats, Python will convert _____ -
ANS-ints to floats
\In modern Python, an int value that grows larger than the underlying hardware int ____ -
ANS-uses more memory
\In order to use functions in the math library, a program must include ____ - ANS-an import
statement
\In Python getting user input is done with a special expression called ____ - ANS-input
\One difference between a compiler and an interpreter is ____ - ANS-a compiler is no longer
needed after a program is translated
\T/F A chaotic function can't be computed by a computer. - ANS-FALSE we literally wrote the
chaos.py program that computes a chaotic function
\T/F A counted loop is designed to iterate a specific number of times. - ANS-TRUE
\T/F A function definition is a sequence of statements that defines a new command. -
ANS-TRUE
\T/F A hardware float can represent a larger range of values than a hardware int. -
ANS-TRUE
\T/F A loop is used to skip over a section of a program. - ANS-FALSE a loop is used to
repeat a section of code
\T/F A programming environment refers to a place where programmers work. - ANS-FALSE
a programming environment is a program designed to help programmers write programs
\T/F A Python int can represent indefinitely large numbers. - ANS-FALSE Python is limited
by the amount of computer memory available.
\T/F A variable is used to give a name to a value to it can be referred to in other places. -
ANS-TRUE
\T/F All information that a computer is currently working on is stored in main memory. -
ANS-TRUE
\T/F An algorithm can be written without using a programming language. - ANS-TRUE
\T/F Computer science is the study of computers. - ANS-FALSE the fundamental question is
"what can be computed?"
\T/F Computers represent numbers using base 2 representations. - ANS-TRUE