Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please answer: Group of answer choices Question 1: What is the Python keyword that begins a function definition? begin func function def Question 2 Within

Please answer: Group of answer choices

Question 1:

What is the Python keyword that begins a function definition?

begin

func

function

def

Question 2

Within a function header, for example:

def basal_metabolic_rate(gender, weight, height, age):

The variables that appear within parentheses are called what?

Group of answer choices

variables

attributes

parameters

arguments

Question 3

Within a function call, for example:

rate = basal_metabolic_rate("F", w, h, years)

The values that appear within parentheses are called what?

Group of answer choices

variables

attributes

parameters

arguments

Question 4

Given this function header:

def compute(x, y, z):

And this code to call that function:

x = 7 result = compute(3, 2, x)

Within the function compute, what value will be stored in the parameter x ?

Group of answer choices

2

3

7

None of the above

Question 5

What is wrong with the following function definition?

def area circle(radius): """Compute and return the area of a circle.""" area = math.pi * radius ** 2 return area

Group of answer choices

The function name includes a space character.

The function has no parameters.

The function redefines its parameter.

The function doesn't return a value.

Question 6

What is wrong with the following function definition?

def kilometers_from_miles(miles): """Convert a value in miles to kilometers and return the kilometers value. """ miles = float(input("Please enter a distance in miles: ")) km = miles * 1.60934 return km

Group of answer choices

The function has no parameters.

The function redefines its parameter.

The function is too short.

The function doesn't return a value.

Question 7

What is wrong with the following function definition?

def torus_volume(inner, outer): """Compute and return the volume of a torus.""" vol = 2 * (math.pi * inner) ** 2 * outer

Group of answer choices

The function has no parameters.

The function redefines its parameter.

The function is too short.

The function doesn't return a value.

Question 8

Within a function, what does the keyword return do? (Select all that apply.)

Group of answer choices

cause the computer to stop executing the current function

return a value to the call point

display a value for a user to see

cause the computer to resume executing code after the call point

Question 9

Which of the following is a tkinter function that can draw a line?

Group of answer choices

create_line

draw_line

fill_line

draw_oval

Question 10

Which of the following is a tkinter function that can draw a circle?

Group of answer choices

create_circle

create_ellipse

create_oval

create_rectangle

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

DATABASE Administrator Make A Difference

Authors: Mohciine Elmourabit

1st Edition

B0CGM7XG75, 978-1722657802

More Books

Students also viewed these Databases questions

Question

DESCRIBE the three types of e-learnin g.

Answered: 1 week ago

Question

18. If you have power, then people will dislike and fear you.

Answered: 1 week ago