Consider a sequence of numbers to have repetitions, how a cartesian tree can be constructed in such situations without violating any rules?
Consider a sequence of numbers to have repetitions, how a cartesian tree can be constructed in such situations without violating any rules? Correct Answer use any tie-breaking rule between repeated elements
Consider any of the tie breaking rules, for example the element which appears first can be taken as small among the same elements and then apply cartesian tree rules.
মোঃ আরিফুল ইসলাম
Feb 20, 2025