initial code for distinct #97