Example & Tutorial understanding programming in easy ways.

Swap two number without using third variable in Python ?

program:

a=10

b=2

print(a,b)

a=a+b

b=a-b

a=a-b

print(a,b)

output:

10,2

2,10

Read More →