hdu-1561.cpp Accepted and Described