windinthetrees windinthetrees
  • 02-04-2021
  • Computers and Technology
contestada

8. What's the output of this code?
1
def sum(x, y):
return(x+y)
print(sum (sum(1,2), sum(3,4)))

Respuesta :

HonoraryPhd
HonoraryPhd HonoraryPhd
  • 02-04-2021

Answer:

10

Explanation:

[tex]sum(1,2) = 3\\sum(3,4) = 7\\sum(3,7) = 10\\[/tex]

Basically, sum((1+2) + (3+4)) = sum(3,7) = (3+7) = 10

Answer Link

Otras preguntas

how did the atlantic slave trade lead to the stagnation of african cultures and economies
what happens to the circulatory system when someone coughs? and what happens to the respiratory system when someone coughs?
Find five things that are the same in the two pictures, and five diferences between them.
Issac has completed two more pieces of homework then Richard who submitted X pieces of homework for the semester if the total number of pieces of homework submi
Which is most likely the target audience for this example? Apex
Which is an act of violence that can occur during daiting
A microscope has an objective lens with a focal length of 1.82 mm. The lenses are 47.8 cm apart What should the focal length of the eyepice be if I want the mic
Compare and contrast epidural and subdural hemorrhages.
The following best describes the bourgeoisie O a wealthy social class that exploits the working classes affluent middle-class people who hire workers O a catego
wich of the following is correctly written citation for an internet article without an author​