Python
print('Enter two number :\n')
Try it Yourself ➠
Swapping using 3rd variable in PYTHON
12 May
0
Write a program (WAP) in PYTHON to read two numbers from keyboard(User Input) and exchanging the value of two variable(Swapping).
print('Enter two number :\n')
a = input()
b = input()
print("Before swapping :\nA = ", a)
print("B = ", b)
temp = a
a = b
b = temp
print("After swapping :\nA = ", a)
print("B = ", b)
Try it Yourself ➠
Also Read :-
Programs of C
Programs of C++
Programs of Java
Programs of Python
Codes with HTML, CSS, JS
More Questions & Answers
Previous article
Next article
Leave Comments
Post a Comment