All preorder values will be distinct


#1

It is not mentioned that all the values of a given preorder will be distinct. Otherwise the accepted solution doesn’t work.