演員表<int>列出<string>在 .NET 2.0 中 - Cast List<int> to List<string> in .NET 2.0

問題:

Can you cast a List<int> to List<string> somehow?你能以某種方式將List<int>List<string>嗎?

I know I could loop through and .ToString() the thing, but a cast would be awesome.我知道我可以遍歷和 .ToString() 的東西,但演員會很棒。

I'm in C# 2.0 (so no LINQ ).我在 C# 2.0 中(所以沒有LINQ )。


解決方案:

參考: https://stackoom.com/en/question/Bgs
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章