Path: utzoo!utgpu!news-server.csri.toronto.edu!mailrus!cs.utexas.edu!uunet!ficc!peter From: peter@ficc.uu.net (Peter da Silva) Newsgroups: comp.lang.c Subject: Re: Brain Teaser Summary: It's possible. Message-ID: Date: 30 Mar 90 02:01:19 GMT References: <99@demott.COM> <1990Mar29.170608.7565@kfw.COM> Distribution: na Organization: Xenix Support, FICC Lines: 13 swap(x,y,len) char *x, *y; size_t len; { while(len>0) { *x^=*y; *y^=*x; *x^=*y; x++; y++; len--; } } Usage: swap(x, y, sizeof(x)); Sort of a pyrrhic victory, though. -- _--_|\ `-_-' Peter da Silva. +1 713 274 5180. . / \ 'U` \_.--._/ v