subject

Read the following code, written to calculate an average: def main(): num1 = 85 num2 = 95 num3 = 91 average = num1 + num2 + num3 / 3 print("Average: " + str(average)) main() Which line of code has an error and why? average = num1 + num2 + num3 / 3; It does not use quotation marks to indicate the string literal. average = num1 + num2 + num3 / 3; It does not follow the proper order of operations. print("Average: "str(average)); It requires an equal sign to properly calculate the output. print("Average: "str(average)); It requires a float() function to properly display the output

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 01:50
Create a class named majors that includes an enumeration for the six majors offered by a college as follows: acc, chem, cis, eng, his, phys. display the enumeration values for the user, then prompt the user to enter a major. display the college division in which the major falls. acc and cis are in the business division, chem and phys are in the science division, and eng and his are in the humanities division. save the file as majors.java.
Answers: 2
question
Computers and Technology, 24.06.2019 10:30
This device directs network traffic. bridge hub nic repeater router switch
Answers: 3
question
Computers and Technology, 24.06.2019 17:00
The length of time that a slide appears before automatically advancing to the next slide can be set in the timing group under the transitions tab. transition to this slide group under the transitions tab. timing group in the master slide view. transition to this slide group in the master slide view.
Answers: 1
question
Computers and Technology, 24.06.2019 17:50
Acontact list is a place where you can store a specific contact with other associated information such as a phone number, email address, birthday, etc. write a program that first takes in word pairs that consist of a name and a phone number (both strings). that list is followed by a name, and your program should output that name's phone number.
Answers: 1
You know the right answer?
Read the following code, written to calculate an average: def main(): num1 = 85 num2 = 95 num3 = 91...
Questions
question
Mathematics, 16.12.2019 19:31
Questions on the website: 13722363