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

A cone is placed inside a cylinder. The cone has half the radius of the cylinder, but the height of each figure is the same. The cone is tilted at an angle so i
Mo jorge rosas. nací el 26 de enero de 1952. mi esposa murió el año pasado. tengo dos hijos: marina y daniel. terminé mis estudios de sociología en la universid
What is the difference between an image and a pre-image in a transformation? How do you tell them apart?
what was the great schism
You're at a friend's house, and his parents are serving alcoholic drinks to the teenagers. You're not interested, but your friend and his parents try to convinc
The Taft-Hartley Act intended to do which of the following?
What is another way to write 2.50%?
find the surface area
where do you see yourself in five years?
7^16/7^12=7^-18/? what is the missing denominator