A string is perfect if it has the smallest lexicographical ordering among its cyclic rotations.For example: "0101" is perfect as it is the smallest string among .Given a 01 string, you need to split it into the least parts and all parts are perfect.
A string is perfect if it has the smallest lexicographical ordering among its cyclic rotations. For example: "0101" is perfect as it is the smallest string among ("0101", "1010", "0101", "1010"). Given a 01 string, you need to split it into the least parts and all parts are perfect.

(图片来源网络,侵删)