Remove maximum ambiguity
Separate helper functions