예제 #1
0
 //依元素獎金排序
 private int SortByPrize(PrizeCombination x, PrizeCombination y)
 {
     if (x.prizeMoney > y.prizeMoney)
     {
         return(1);
     }
     if (x.prizeMoney < y.prizeMoney)
     {
         return(-1);
     }
     return(0);
 }
예제 #2
0
 //依元素數量排序
 private int SortByAmount(PrizeCombination x, PrizeCombination y)
 {
     if (x.combinations.Count > y.combinations.Count)
     {
         return(1);
     }
     if (x.combinations.Count < y.combinations.Count)
     {
         return(-1);
     }
     return(0);
 }