I added the lead-in lead-out to the program just befor posting it and it has occurred to me to mention that the program assumes the center of the hole drops out at the end of the cutout. If it does not, then the move to the start of the lead-in might catch the cutout hole center.
The lead-in radius is a user input so you can effectively eliminate the lead-in without changing the program, if you cannot arrange for the center to drop out.