refactoring + printing the limits