///數字與數組或者字符串裡面的內容比較 /// </summary> private void YunXing() { int[] cs = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 }; List<int> strList = new List<int>(); strList.AddRange(cs); bool b; for (int i = 0; i < strList.Count; i++) { if (strList[i] == i) { MessageBox.Show(i.ToString()); } //} } }