in reply to Re^2: Finding the dates for the reminder mail system
in thread Finding the dates for the reminder mail system

Not using use strict; and use warnings; is bad enough. Asking why code doesn't work without turning them on and fixing the errors is even worse. It would have immediately pointed out why $days_to_wed and $days_to_fri contain the wrong values.