多测害的,你在solve函数里反复开大数组导致超时。稍微改了改就过了:https://ac.nowcoder.com/acm/contest/view-submission?submissionId=75420984