Refactoring: getNoteLengths() -> getDuration()