im a noob in c++ and i have a project to pass this weekend.. and i badly need help..

help me out please..

i need to:

find a 4-digit number that the difference between their digits arranged from greatest to smallest and smallest to greatest is the original number. (a<b<c<d) - (d<c<b<a) = original number.

please hep me out..

T____T