Time limit
4000 ms
Memory limit
65536 kB
OS
Linux
Source
SDOI2009
Descriptions:

HH的项链

HYSBZ - 1878