MohdMubasshir
MohdMubasshir MohdMubasshir
  • 24-09-2020
  • Computers and Technology
contestada

15. Write a program in python to read three numbers in three variables and swap first two variables with the sums of
first and second, second and third numbers respectively.​

Respuesta :

tonb
tonb tonb
  • 24-09-2020

Answer:

a = int(input("Enter first number: "))

b = int(input("Enter second number: "))

c = int(input("Enter third number: "))

a,b = a+b,b+c

print(a,b,c)

Explanation:

Assignments like this are easy in python, in the sense that no helper variables are needed!

Answer Link

Otras preguntas

Many communities have zoning boards that decide what is the best way to use town or city property. Imagine you are a member of the Clayton Zoning Board looking
if you have 4 2/3 and you cut into 2/5 how many 2/5 would it take
The secret garden story What is one of Mary's biggest struggles?
ill give you brainliest please be quick
what is smart in project managment
6th grade math please give a straight up answer 100 points A middle school recorded the following donations received during its fundraiser for the school's ban
(घ) rDNA में 'r' क्या है? (ङ) निकेत को परिभाषित कीजिए। अतिलघ उत्तरीय 192 ​
the graph of the function f shown consists of three line segments. if g is the function defined by g(x)=∫x,0 f(t)dt, then g(-1)=
if $26000 is invested at 2.25% compounded continuosly, what is the amount after 15 years? A=P^ert
Discuss the special health challenges in South Africa and the role of the "Train of Hope"