Refactor -main to know very little, adding calculate-range, format calculate's cond