EspaƱol
|
Donate
Home
Favorite Links
StackOverflow
Google
W3 Schools
Linux
Apache
MySQL
PHP
LAMP >
Packagist
NPM
My Site
Tutorials
Cisco
LAMP
Miscellaneous
Notes
Contact Me
Avatar
Search
Search
Categories
Main (5)
Tutorials (1)
- Cisco Tutorials (6)
- LAMP Tutorials (0)
- Misc. Tutorials (1)
Amazon Wish List (1)
Notes (1)
- Java Notes (2)
- Elixir Notes (4)
- C Notes (5)
- Cisco Notes (36)
- Linux Notes (50)
- Bash Notes (7)
- Apache Notes (3)
- MySQL Notes (17)
- PHP Notes (29)
- Nginx Notes (3)
- MongoDB Notes (1)
- Riak Notes (3)
- Node.js Notes (1)
- Redis Notes (3)
- Python Notes (3)
- Misc. Notes (10)
Calendar
«
September 2012
»
Sun
Mon
Tue
Wed
Thu
Fri
Sat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
01/24/2025
Links
Blog Home
Contact
Stats
About this Blog
About Me
Tutorials License
Login
How to swap two numbers (2 variables) without using third variable.
Tuesday, September 4, 2012, 08:01 PM -
- PHP Notes
//Interview question
#input:
num1=50;
num2=100;
#core logic
num1 = num1 + num2;
num2 = num1 - num2;
num1 = num1 - num2;
#output
num1 is 100
num2 is 50
Comments
Comments are not available for this entry.
2025 By Angel Cool