There are many constraints to satisfy, and avoiding hills is but one of them.
Most of us would take a hill with a protected bike lane over a flat 45mph.