(adsbygoogle = window.adsbygoogle || []).push({ google_ad_client: "ca-pub-2960223314593660", enable_page_level_ads: true }); Program to swap two numbers - TecGlance

Header Ads

Program to swap two numbers



==================== SWAP NUMBERS ===============



 a=input("Enter The First Number  :")

 b=input("Enter The Second Number :")

 print "Before SWAPPING  a= ",a," b= ",b

 c=a

 a=b

 b=c

 print " After SWAPPING  a= ",a," b= ",b





===================OUTPUT ======================



 Enter The First Number  :15

 Enter The Second Number :26

 Before SWAPPING  a=  15  b=  26

 After SWAPPING  a=  26  b=  15



=================================================

No comments

Powered by Blogger.