my java code went wrong with the 13th test, and i don't know why.Can anyone help me.

public class Solution {

public int[] twoSum(int[] nums, int target) {

int b=0,c=0;

```
for(int i=0;i<nums.length;i++){
for(int k=0;k<nums.length;k++){
if(k!=i){
if((nums[i]+nums[k])==target){
c=k;
break;
}
}
}
if(c!=0){
b=i;
break;
}
i++;
}
int[] a={b,c};
return a;
}
```

}