a kata for practicing a refactoring:  template method -> strategy pattern