Created With

linkIn-Place Swapping

Swap two values x and y in-place, without using any helper variables.

swap.py
1linkx = 5

2linky = 10

3link

4linkx ^= y

5linky ^= x

6linkx ^= y

description

15-Feb-2021

In-Place Swapping

Home

Project Eulerchevron_right
Essayschevron_right
Blogschevron_right

Awesome Stuff