Я только что выполнил Задачу по программированию Greplin и перешел на последний уровень, где задача звучит так:
For the final task, you must find all subsets of an array
where the largest number is the sum of the remaining numbers.
For example, for an input of:
(1, 2, 3, 4, 6)
the subsets would be
1 + 2 = 3
1 + 3 = 4
2 + 4 = 6
1 + 2 + 3 = 6
Here is the list of numbers (3, 4, 9, 14, 15, 19, 28, 37, 47, 50, 54, 56, 59, 61, 70, 73, 78, 81, 92, 95, 97, 99)
you should run your code on.
The password is the number of subsets. In the above case the
answer would be 4.
Можете ли вы дать мне совет, что мне делать?делать здесь?Я думаю, что грубая сила здесь не подходит, не так ли?
Не пишите код!
Спасибо.