MathDB
1 - (2 + 3 - (5 + 6 - (7 + 8 - (10 +...)))) =n

Source: 2006 Estonia Open Olympiad Junior p1

March 27, 2020
algebraequation

Problem Statement

The paper is written on consecutive integers 11 through nn. Then are deleted all numbers ending in 44 and 99 and the rest alternating between - and ++. Finally, an opening parenthesis is added after each character and at the end of the expression the corresponding number of parentheses: 1(2+3(5+6(7+8(10+...))))1 - (2 + 3 - (5 + 6 - (7 + 8 - (10 +...)))). Find all numbers nn such that the value of this expression is 1313.