Перебор
timus : 1152
Задача Fool (statement = 101016, problem F)
Задача Polyomino (statement = 101023, problem G)
Задача String Decomposition (statement = 101009, problem K)
contest = 101027a1