随笔分类 - C#
摘要:废话不多说,直接看代码。 string s = "aabbccddeeffgghh"; //方法一 string s1 = s.Replace("a", ""); int a1Length = s.Length - s1.Length; //方法二 int a2Length = 0; for (int i...
阅读全文
摘要://取CPU编号 public String GetCpuID() { try { Manageme...
阅读全文
摘要:冒泡排序 using System; namespace BubbleSorter { public class BubbleSorter { public void Sort(int [] list) { int i,j,temp; bool done=false; j=1; while((j<list.Length)&&(!done)) { done=true; for(...
阅读全文
浙公网安备 33010602011771号