Exam 5: Functions and Modules

arrow
  • Select Tags
search iconSearch Question
flashcardsStudy Flashcards
  • Select Tags

A(n) _____ constant is a global name that references a value that cannot be changed.

(Multiple Choice)
4.9/5
(35)

The hierarchy chart shows all the steps that are taken inside a function.

(True/False)
4.8/5
(42)

What type of function can be used to determine whether a number is even or odd?

(Multiple Choice)
4.9/5
(43)

In a flowchart, a function call is depicted by a(n) _______________ that has vertical bars.

(Short Answer)
4.7/5
(42)

A value-returning function is _____.

(Multiple Choice)
4.9/5
(38)

A(n) _____ variable is created inside a function.

(Multiple Choice)
4.7/5
(28)

What is the result of the following statement? X = random.randint(5, 15) * 2

(Multiple Choice)
4.9/5
(41)

Python function names follow the same rules for naming variables.

(True/False)
4.8/5
(37)

The approach called _______________ is taking a large task and dividing it into several smaller tasks that are easily performed.

(Short Answer)
4.9/5
(35)

What does the following statement mean? Num1, num2 = get_num()

(Multiple Choice)
4.7/5
(42)

Functions in the standard library are stored in files that are known as _______________.

(Short Answer)
4.8/5
(33)

In Python, there is no restriction on the name of a module file.

(True/False)
4.9/5
(44)

Arguments are passed by _______________ to the corresponding parameter variables in the function.

(Short Answer)
4.8/5
(33)

The math function, atan(x), returns one tangent of x in radians.

(True/False)
4.9/5
(32)

It is recommended that programmers should avoid using _____ variables in a program when possible.

(Multiple Choice)
4.8/5
(29)

The 'P' in the acronym IPO refers to _______________.

(Short Answer)
4.8/5
(33)

The function header marks the beginning of the function definition.

(True/False)
4.8/5
(33)

The top-down design breaks down the overall task of the program into a series of _______________.

(Short Answer)
4.8/5
(38)

The function header begins with the keyword _______________ followed by the name of the function.

(Short Answer)
4.8/5
(32)

To assign a value to a global variable in a function, the global variable must first be declared in the function.

(True/False)
4.9/5
(32)
Showing 21 - 40 of 69
close modal

Filters

  • Essay(0)
  • Multiple Choice(0)
  • Short Answer(0)
  • True False(0)
  • Matching(0)