add minor notes in code