天天看點

c#截取後幾位

string s = "1234567";

string last6chars = new string(s.reverse().take(6).reverse().toarray());//先反轉順序,從開頭截取指定數量的字元,再反轉順序

繼續閱讀