Recently, an article appeared in Habré, in which a link to the game 2048 was published. There you can also read the rules in more detail and try to sit down for this fascinating thing (quite a number of habrayusers have already indulged in this).
The students of the Physics Department also had fun, so we came up with a simple heuristic winning (at least we managed to score 2048 9 out of 10 times) the strategy of this game.
Enumerate consecutive columns (rows are possible, but later I will talk about columns) from 1 to 4 (successively from left to right or from right to left). The underlying principle of the strategy is the arrangement of numbers, in which we completely fill the 1st column with the largest available numbers. At the same time, in the 2nd column the numbers are on average less than in the 1st, and in the 3rd it is less than in the 2nd. Moreover, only at the last stages of the game in the 3rd column, the appearance of numbers of average denomination is possible (somewhere up to 32). ')
From this principle, it follows that when choosing a move, we must give preference to one that increases the number of first columns. Thus, we always preserve the gradient of filling numbers and, accordingly, do not deviate from the above principle.
For example, using the left column as the 1st column, we will never use the → key, so as not to deviate from the principle.
Significant subtle nuance: when filling in the selected columns, you need to avoid a situation where the new number that appears can completely fill the column so that we have to make a move → that completely eliminates the possibility of continuing to play according to our strategy.