The loop beginning on line 8 will never ever execute more than once because of the return statements on lines 16 and 18.
>>&& 2 == b - a ==> line 23
That will not work when the value of a > b. You need to consider someone entering 5 and 3 instead of the other way around.
Ancient Dragon
Retired & Loving It
30,049 posts since Aug 2005
Reputation Points: 5,662
Solved Threads: 2,343