在Fruit(Fruit f)构造函数中的for循环之间加上下面这一行即可。s = new Seed[seeds];