Exemple #1
0
    public static int FoodAdd(Money.Food food)
    {
        switch (food)//10,17,25
        {
        case Food.馒头:
            return(20);

        case Food.稀粥:
            return(50);

        case Food.玉米:
            return(80);

        default:
            return(0);
        }
    }
Exemple #2
0
    public static int FoodMoney(Money.Food food)
    {
        switch (food)
        {
        case Food.馒头:
            return(-1);

        case Food.稀粥:
            return(-2);

        case Food.玉米:
            return(-3);

        default:
            return(0);
        }
    }