语句 Ziziq · 2024-05-08 16:17:33 · 算法·理论 substr 截取 string 的一段 string a="abcd"; cout<<a.substr(1)<<"\n";//bcd cout<<a.substr(2,2)<<"\n";//cd