# [Community Puzzle] Find the missing plus signs in addition

Coding Games and Programming Challenges to Code Better

Validated by @cedricdd,@papyjo and @pluieciel.
If you have any issues, feel free to ping them.

Hi,
Iâ€™m slightly confused. I have failed last TestCase named â€ś59 digits in Oâ€ť but event though after submiting my code I got 100%.
Remove the test case or add validator to make it consistent, so no one will waste time for optimizing if thatâ€™s not required.

Regards,
BigZettt

Same thing happened to me, but I donâ€™t think itâ€™s a problem. Itâ€™s better if the validator has a slightly lower treshold than the testcase than the opposite. Imagine if you finally pass the last testcase and submit and it timeouts, it would be even more irritating.
There are many possible optimizations for this problem, if you add them one by one, at some point itâ€™s good enough and thatâ€™s it.
The fact that we both landed right between testcase treshold and validator treshold is a bit unfortunate but the puzzle creator cannot anticipate everything in every language.
And if we want to pass both testcase and validator we can try to optimize a bit more.

3 Likes

I am in the same boat as you. However, I noticed that pluiecielâ€™s code passes all test cases and all validators. Iâ€™m working through that code right now to try to figure out what I missed.

Well, now I am just mad that I did not fight hard enough to pass the last test case. I have been through @pluieciel code and the algorithm is brilliant. I agree with @BigZettt that the validator should be made a bit tougher so that the less than adequate algorithm I put together cannot get 100% when submitted.

What about zeros? Is this test valid?
3
7
3004
3+0+04=7
3+00+4=7

Hi,

The way the zeros should be handle is not defined in this puzzle, there are no zeros in any of the tests/validators.

The â€śminiâ€ť function is from the author. I spent too much time trying to pass the â€ś59 digits in Oâ€ť with Clojure (still not successful). My Clojure solution finally passed the validator at the limit-lineâ€¦(i.e. need to submit several times and pray for luck :))) )
On my laptop, the last Test takes â€śElapsed time: 38385.4 msecsâ€ť, but last Validator only takes â€śElapsed time: 5396.7 msecsâ€ť (about 8 times faster). I guess thatâ€™s why some solutions can pass validator but not last testâ€¦
Still trying to optimize my Clojure solution.

Hello @cedricdd, @pluieciel I am having a problem here.
I can pass the tests, but I fail two of the vaidator tests. I suspected that this was due to the sorting required, and fixed that (I think) but I still fail two of the validators (â€śAnother with more than one solutionâ€ť and â€śTen terms againâ€ť)
Any help is welcome as I have absolutely no idea of the reason for which they fail.