Updated to pass planC as an optional argument.