A man sold his television for $160 and he suffered a loss of 20%. At what price should he have sold the television to have earned a gain of 20%?

160 = X * 0.8
X = 160 / 0.8 = 200.
R = 200 * 1.2 = 240