Problem 1780 · Medium
Decide whether n is a sum of distinct powers of three.
Open the interactive visualisation