subject

Define stubs for the functions get_user_num() and compute_avg(). Each stub should print "FIXME: Finish function_name()" followed by a newline, and should return -1. Each stub must also contain the function's parameters. Sample output with two calls to get_user_num() and one call to compute_avg():

FIXME: Finish get_user_num()

FIXME: Finish get_user_num()

FIXME: Finish compute_avg()

Avg: -1

code to fill in:

''' Your solution goes here '''

user_num1 = 0

user_num2 = 0

avg_result = 0

user_num1 = get_user_num()

user_num2 = get_user_num()

avg_result = compute_avg(user_num1, user_num2)

print('Avg:', avg_result)

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 16:50
3.2.5 suppose that we have an estimate ahead of time of how often search keys are to be accessed in a bst, and the freedom to insert items in any order that we desire. should the keys be inserted into the tree in increasing order, decreasing order of likely frequency of access, or some other order? explain your answer.
Answers: 1
question
Computers and Technology, 22.06.2019 17:00
Acase study allows a more detailed look at the life of a single subject than any other study.
Answers: 3
question
Computers and Technology, 22.06.2019 17:30
Rachel completed typing an official document with a word processing program. she wants to make sure that her document has no typographical errors. she also wants all headings to have the same font. which features in a word processing program should she use? rachel should use the feature in a word processing program to find typographical errors. she should apply to have uniform headings.
Answers: 1
question
Computers and Technology, 22.06.2019 21:40
Develop a function to create a document in the mongodb database “city” in the collection “inspections.” be sure it can handle error conditions gracefully. a. input -> argument to function will be set of key/value pairs in the data type acceptable to the mongodb driver insert api call b. return -> true if successful insert else false (require a screenshot)
Answers: 2
You know the right answer?
Define stubs for the functions get_user_num() and compute_avg(). Each stub should print "FIXME: Fini...
Questions
question
Computers and Technology, 29.01.2021 21:40
question
Mathematics, 29.01.2021 21:40
question
Mathematics, 29.01.2021 21:40
Questions on the website: 13722363