Max runnning time is 10! Given any set letters could only be assigned
values of {0,1,...9}.
thanks
Arun prasath N
On Nov 2, 9:43 pm, "Lego Haryanto" <[EMAIL PROTECTED]> wrote:
> A "quicker" brute force (not the one with 10! complexity) is by doing a
> recursion starting from the rightmost digit.
A "quicker" brute force (not the one with 10! complexity) is by doing a recursion starting from the rightmost digit.
The number of levels in the recursion is the same as the longest digits (in the sample case: 5, which is length of MONEY). After we processed 5 levels, we know we got a solution.