我有一個列表。StartsWith和List的使用情況列表<string>?
這是可能的成員(x123,y123,z123,a123,b123,c123).//123是example 這個「mylist」可能包含一個以x開頭的成員,或者不可以。這對y,z,a,b,c也是一樣的。
If contains a member starts with x:
//Formula Contains X
If Not Contains a member starts with x:
//Formula Not Contains X
//same as all of x,y,z,a,b,c. But unlike a foreach, I must place the formulas at checking time, not after.
我該怎麼做?
你使用LINQ? –
這不會是一個問題,重要的是工作,我可以使用。 – ithnegique
好的。我發佈了一個包含答案並且不包含 –