Editing score function