Casting to double here doesn't make much sense as we are comparing integers here.