For all the examples, one and only code for each example was sufficient to cover both the line/code coverage and the branch coverage. That's why one and only code for each example was implemented.
Line coverage's result is 91 percent The "return true" line is not covered The issue was the incrementation of j and i: "j++;i--;" The correct is "i++; j--;"
The old method has an issue with the loop: for (int i = 0; i <= s1.length(); i++), which causes "ArrayIndexOutOfBoundsException" The correct one is the new: for (int i = 0; i < s1.length(); i++)
N.B. This method is wrong: The condition "while (low < high)" will be changed into while (low <= high) in order to consider the case low equals high
Probably it is better to throw an exception too when delta < 0 Fours tests are sufficient
No other remarks
No other remarks