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
Alex
2 years ago
11

Edhesive 7.6 lesson practice python

Computers and Technology
1 answer:
spayn [35]2 years ago
6 0

Answer:

(a) The output is -1

(b) The output is 32

Explanation:

Given: The above code

Solving (a): The output when 1, 1 and 1 is passed to the function

From the question, we have: print(mystery(x))

This means that only the value of x (which in this case is 1) will be passed to the mystery function

(a, b = 8, c = -6) will then be seen as: (a = 1, b = 8, c = -6)

2 * b + a + 3 * c = 2 * 8 + 1 + 3 * -6

2 * b + a + 3 * c = -1

<em>The output is -1</em>

Solving (b): The output when 8, 6 and 4 is passed to the function

From the question, we have: print(mystery(x,y,z))

This means that values passed to the function are: x = 8, y = 6 and z = 4

(a, b = 8, c = -6) will then be seen as: (a = 8, b = 6, c = 4)

2 * b + a + 3 * c = 2 * 6 + 8 + 3 * 4

2 * b + a + 3 * c = 32

<em>The output is 32</em>

You might be interested in
Which PlayStation was the first to allow connection between it and computer network
Bezzdna [24]

If you're talking about connecting to the internet internet, it would be the PS2. You could buy an adapter for an ethernet cable to allow for online play.

4 0
3 years ago
Which web browser was created by Google?
Natali5045456 [20]

Answer:

Chrome

Explanation:

6 0
3 years ago
Read 2 more answers
The automotive system that connects the engine and the transmission to the wheels is called the
insens350 [35]
I believe the driveshaft 

8 0
3 years ago
Function prototypes and function definitions look similar because they have the same function heading. In a function prototype t
hjlf

Answer:

In a function prototype the heading is followed by a semicolon, whereas in a function definition the heading is followed by a function block.

Explanation:

As the function prototype only declares the function and the function definition defines the operations in the function.

e.g:

add(int x, int y);  is the prototype

add(int x, int y)

{

     int sum;

     sum = x+y;

}    is the function definition.

3 0
3 years ago
What does the shell of an operating system do
Andre45 [30]

The OS shell allows access to the operating system services

8 0
2 years ago
Other questions:
  • It is used to replace numeric number of a website​
    7·1 answer
  • What are the features of the Outline view in Word? Select three options.
    12·2 answers
  • Where is line-of-sight Internet common?<br> In space<br> Outdoors<br> Inside<br> In businesses
    5·1 answer
  • What are factors that limit a technological design
    11·2 answers
  • Implement RandMultipByVal function, which gets one integervariable as its argument
    12·1 answer
  • What two pieces of information would you need in order to measure the masses of stars in an eclipsing binary system?
    9·1 answer
  • Explain what is meant by information technology (IT). Explain what is meant by information systems (IS). Why is it important to
    7·1 answer
  • Fill in the blanks in the SQL statement below that will list the invoice number, invoice total and credit which is the total sum
    14·1 answer
  • Which is a benefit of peer-to-peer networking?
    12·1 answer
  • What are the minimum number of bits an address bus must have in a byte addressable memory system containing only 4 KiB of memory
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!