为什么最后会报错?
public static int count(int n){
int result;
result = n/4+count(n-4);
if (n<0)
result = 0;
return result;
}
public static void main(String[] args){
System.out.println(count(5));
}
Exception in thread "main" java.lang.StackOverflowError
at huam.count(huam.java:4)
at huam.count(huam.java:4)
at huam.count(huam.java:4)
at huam.count(huam.java:4)