Home > Back-end >  To solve the BugJAVA
To solve the BugJAVA

Time:09-29



He said I an array, but I don't see, how to change?

CodePudding user response:

Array number 50, foot mark from 0 ~ 49
You use the 50 feet, the more certain the
So can't write & lt;=m & lt;=n
To write & lt; M & lt; n

CodePudding user response:

Certainly not equal to 50, you define, int socre [] []=new int [50] [6]
Is a length of 50 array, each consists of a length of 6 subarray,
But the array subscript from zero beginning, is also the biggest is also to score [49] [5], you are such a for loop until i<=m (50), is to be able to pick up to 50, certainly when cross-border
Ps: define array subscript starts from the 1, and use when starting from 0

CodePudding user response:

I changed, not equal to 50 was not

CodePudding user response:

You can't change of m and n, you want to change the for loop, the i< inside;=m and j<=n=number of removed
  • Related