Question link >> XORNEY Problem - CodeChef
my solution >>CodeChef: Practical coding for everyone
Use llabs(a-b). abs returns an int, so that causes an overflow.
llabs(a-b)