IOM 2019, Блиц — Задача 7

OLYMPIAD OF METROPOLISES, Moscow, September 2, 2019 · 2 септември 2019 г.

Условие

You have a string. You are allowed to perform two types of operations. 1. Add two equal characters to some position. Examples: AA -> ABBA, AA -> CCAA.

  1. Delete a substring in the form XYX where X and Y are different characters. Examples: BABA -> A, BABA -> B, you cannot delete CCC, because characters must be different.

What is the minimal number of such operations required to turn the string "ABC" into the empty string?

Решение

Внимание: Непълно решение

В архива няма официално решение на тази задача.


Оригинал в Архива: blitz-en-all-task-final.pdf