TopCoder SRM 708 Div1 Medium PalindromicSubseq

何とか本番中に解けてよかった。 https://community.topcoder.com/stat?c=problem_statement&pm=14526