DataEntity Sort() { DataEntity dt = Data; for (int i = 0; i < Data.Count; i++) { for (int j = i; j < Data.Count; j++) { if (dt[i].Dist > dt[j].Dist) { var pt = dt[i]; dt[i] = dt[j]; dt[j] = pt; } } } return(dt); }
public Algo(DataEntity data, int n) { Data = data; N = n; }