[java新手]小弟我的程序那里有异常?是static不对吗

[java新手]我的程序那里有错误?是static不对吗?
package teacherhome.ex6;

public class CustomerDemo {
public static void main(String[] args) {
Customer customer[]=new Customer [3];
for (int i = 0; i < customer.length; i++) {
customer[i]=new Customer();
}
Production apple=new Production("apple", 15);
Production banana=new Production("banana",20);
Production tomato=new Production("tomato",10);
customer[0].buy(apple, 10);
customer[1].buy(banana, 333);
customer[2].buy(tomato, 666);
}

}
class Customer{
String name;
String address;
String cardNumber;
double avalueNumber=1000;
static double number;
void buy(Production production,double number){
this.number=number;
if(avalueNumber>=0){
avalueNumber=production.getSumPrice();
System.out.println("可用额度: "+avalueNumber);
System.out.println("打折: "+production.getDiscountPer());
System.out.println("优惠: "+production.getDiscount());
}
else{
System.out.println("可用额度: "+avalueNumber);
System.out.println("打折:0 ");

}
}

}
 class Production{
 String name;
 double price;
 //double number;
 double sumPrice;
 double discount;
 Production(String name ,double price){
 this.name=name;
 this.price=price;
 }
 double  getSumPrice(){
 return price*Customer.number*this.getDiscountPer();
 }

 double getDiscountPer(){
 if(this.getSumPrice()<=100)
 return 0.9;
 else if(this.getSumPrice()<=200)
 return 0.8;
 else 
 return 0.7; 
 }
 double getDiscount(){
 return price*Customer.number-this.getSumPrice();
 }
 }

实验内容
编程实现一个模拟的用户消费信用卡的示例,在其中用户Customer类具有用户名、地址、卡号、消费额度、可以享受的打折度等多种个人信息;而CustomerDemo类中建立3个消费者,对其分别进行操作,模拟其行为。  


实验目的  
在前几节介绍了面向对象的基本概念,包括类、对象、属性以及方法。在这个基础上,用两个面向对象的简单程序,继续让读者充分体会面向对象编程的方法。  


实现思路  
简单模拟了一个商店客户折扣卡的功能,自定义Customer类用来保存在某个商店中的客户的折扣卡信息。在主类CustomerDemo中,创建Customer类的一个数组对象,该数组中包含了三个Customer的对象,用来保存三个不同的消费者各自持有的折扣卡信息。通过这三个对象,可以根据用户消费的金额来改变用户在本店中所能享受的折扣价格。

------解决思路----------------------

应该customer类里有个card类,就相当于人持有1个信用卡

customer类还要有个付款的功能(方法),这个方法应该有个参数(购买的物品的价格),付款的时候就要调用信用卡,查看信用卡的信息,对其额度、折扣进行调整,最后要返回这次消费的实际要付款的金额,或则打印出这次消费的信息。