1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Damm [24]
2 years ago
5

Answer coding question please

Computers and Technology
1 answer:
alexira [117]2 years ago
3 0

Answer:

No, see below for explanation.

Explanation:

(Attachments are added for visual reference.)

The code will have <u>NameError</u> if you decide to run as seen in the first attachment. If you notice, it will say that the variable cost is not defined.

This happens because we only define the variable cost inside a function totalCost(a, b). That means the variable will only work inside a function itself and if it's outside of function, the variable will not be able to be called outside of its range.

There are several ways to fix. See the second and third attachment as you notice that both codes work and will have same output. The difference is that the first code will rely on function call and the second will rely on variable cost

In simple answer, the code given will not work because the variable is only defined in a function itself and not globally outside of function..

You might be interested in
Which part of the Office interface is located across the top of the application window and organizes common features and command
aleksklad [387]

Answer:

The correct answer to the following question will be "Ribbon".

Explanation:

  • In the configuration of the computer interface, the ribbon is indeed a graphical controlling feature in the format of a series of toolbars mounted on several tabs. The standard ribbon layout requires large toolbars, loaded with graphical keys, tabbed as well as other visual control features, organized by feature.
  • The aim of the ribbon should be to provide quick and easy access to widely used activities for each system. The ribbon is therefore tailored for each task and includes program-specific commands. Besides, the top of a ribbon contains multiple tabs that can be used to disclose various groups of commandments.

Therefore, Ribbon it the suitable answer.

6 0
3 years ago
How have productivity programs improved the professional lives of people? (check all that apply)
Zielflug [23.3K]

Productivity programs improved the professional lives of people because:

  • made it easier and faster to communicate with others
  • made it easier to manipulate numbers in a spreadsheet
  • made it easier and less expensive to present information

<h3>What is productivity?</h3>

Productivity is known to be the level of efficiency in regards to the production of goods or services and it is one that is rated by some measure.

Hence, Productivity programs improved the professional lives of people because:

  • made it easier and faster to communicate with others
  • made it easier to manipulate numbers in a spreadsheet
  • made it easier and less expensive to present information

Learn more about productivity from

brainly.com/question/14262252

#SPJ1

7 0
2 years ago
1. I write about my travel experiences on my own personal ____?
alekssr [168]

Answer:

Hello There!!

Explanation:

1.blog

2.laptop

hope this helps,have a great day!!

~Pinky~

4 0
3 years ago
Online banking tools allow you to pay bills from your computer. <br> a. True<br> b. False
Vaselesa [24]
On your online bank you can add bills from your computer. 
5 0
3 years ago
Read 2 more answers
Data warehousing is a(n) __________, and data mining is a(n) ____________.
Maksim231197 [3]

Answer:

B. Process, group of techniques

Explanation:

Data warehousing simply means storing large amounts of data from multiple sources to a central "warehouse" to be analyzed or simply stored for later. Data mining on the other hand involves discovering patterns in sets of data to make better decisions. Analyzing data with a group of techniques like statistics and machine learning.

8 0
3 years ago
Other questions:
  • Write the formal descriptions of the following sets: (a) The set containing the numbers 5, 9, and 27. (b) The set that contains
    5·1 answer
  • Which hexadecimal-type address refers to a physical networking device such as a network interface card?
    10·1 answer
  • In basic network scanning, ICMP Echo Requests (type 8) are sent to host computers from the attacker, who waits for which type of
    14·1 answer
  • Katarina is deciding whether to buy a desktop or a laptop computer. What will most likely help Katarina make her decision?
    10·2 answers
  • If a football player had to use the restroom during a play what do they do?
    13·1 answer
  • Package Newton’s method for approximating square roots (Case Study 3.6) in a function named newton. This function expects the in
    7·1 answer
  • Trevor owns a manufacturing business that makes specialized hiking and rock climbing gear. He is a very small player in the mark
    8·1 answer
  • ​ In addition to using national weather sites, you should supplement the local weather information with all of the following EXC
    12·1 answer
  • If the system has a mechanical advantage of 5 and the load of 350N.What effort is needed to lift the weight? Provide your answer
    10·1 answer
  • If you are going to develop a special computer, what would it be and explain it's purpose.​
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!