class Solution { public: int MLS(vector<int>& arr) { // write code here sort(arr.begin(), arr.end()); auto it = unique(arr.begin(), arr.end()); arr.erase(it, arr.end()); //注意一定要先排序再去重,不然达不到去重目的 //不要问我怎么知道,卡半天了,有兴趣可以自己试验一下 int right = 1, left = 0; int sz = arr.size(); if (sz == 1) return 1;...