In article <MYwDEFy00WB842JEUx at andrew.cmu.edu> tg1e+ at andrew.cmu.edu (Timothy R. Gottschalk) writes: <To swap two variables x,y in C without using a temporary variable: < x += y; < y = x - y; < x -= y; <does anyone know an even simpler method? Known as the 'XOR trick': x ^= y; y ^= x; x ^= y; or even: #asm XCHG x,y /* :-) */