{"trustable":true,"sections":[{"title":"","value":{"format":"MD","content":"\u003cp\u003eEach palindrome can be always created from the other palindromes, if a single character is also a palindrome. For example, the string \"bobseesanna\" can be created by some ways:\u003cbr /\u003e\n* bobseesanna \u003d bob + sees + anna\u003cbr /\u003e\n* bobseesanna \u003d bob + s + ee + s + anna\u003cbr /\u003e\n* bobseesanna \u003d b + o + b + sees + a + n + n + a\u003cbr /\u003e\n...\u003cbr /\u003e\nWe want to take the value of function CountPal(s) which is the number of different ways to use the palindromes to create the string s by the above method.\u003c/p\u003e\n\n\n\u003ch3\u003eInput\u003c/h3\u003e\n\u003cp\u003eThe string s\u003c/p\u003e\n\n\u003ch3\u003eOutput\u003c/h3\u003e\n\u003cp\u003eThe value of function CountPal(s), taking the modulo of 1 000 000 007 (10\u003csup\u003e9\u003c/sup\u003e+7)\u003c/p\u003e\n\n\u003ch3\u003eLimitations\u003c/h3\u003e\n\u003cp\u003e0 \u003c |s| \u003c\u003d 1000\u003c/p\u003e"}},{"title":"Sample 1","value":{"format":"MD","content":"\u003ctable class\u003d\u0027vjudge_sample\u0027\u003e\n\u003cthead\u003e\n \u003ctr\u003e\n \u003cth\u003eInput\u003c/th\u003e\n \u003cth\u003eOutput\u003c/th\u003e\n \u003c/tr\u003e\n\u003c/thead\u003e\n\u003ctbody\u003e\n \u003ctr\u003e\n \u003ctd\u003e\u003cpre\u003ebobseesanna\u003c/pre\u003e\u003c/td\u003e\n \u003ctd\u003e\u003cpre\u003e18\u003c/pre\u003e\u003c/td\u003e\n \u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e\n"}}]}