I am trying to complete the “Cryptorithme” puzzle, i wrote my solution and all my tests are success.
But when i try to submit and validate the solution, something goes wrong with the last case.
I don’t understand why it does not work.
However the test cases are exactly the same in the IDE tests and in the final validation, they are 4 tests.
I gave you the validator test in private message. You can do a custom test in the test case panel to investigate the issue in your code. Let me know if you manage.
IDE tests and validator tests are different to prevent hardcoding. However, most of the times, test work as couples and here the “validator 4” tests the same thing as “test 4”.
And there is my problem: the validator and the test are the same… I successfully passed the test but not the validator which are exactly the same (Not the same as yours, maybe there is a version for each language… but it doesn’t matter).
So for the same case: TEST => OK
VALIDATOR => NOK
And that is why it’s making me crazy. incomprehensible
You’re mistaking something somewhere.
No validator is the same as the tests so when you claim validators and tests are the same, you’re not talking about the same thing as Thibaud.
Maybe I didn’t understand the meaning of what Thibaud was talking about. My english is not so good but I still try.
But what I mean is that I can see that the test case in the test panel is exactly the same as the case in the final validator. And I think Thibaud was saying the same thing specially for this puzzle.
So because of my bad english maybe i m not clear :
This is the test panel with IDE:
Hello @SabriM
I’m sorry, my explanation wasn’t detailed enough.
The two tests (ide test and validator) test the same thing indeed (85+15=100) but with different letters.
To investigate the validator test, I sent you by private message (I believe on Monday) the input and expected output of the validator so you can test it yourself. To do so, you must activate “expert mode”. I though you had it activated but it seems you don’t. In the settings panel, you have “mode”, choose “expert”. Now you can test a “custom test case”.
Don’t hesitate to ping me on Discord or on the chat here if you don’t manage. Hope it helps.
Sorry guys, I didn’t actually have any knowledge about the expert mode and the custom test cases.
Thank you so much for your help Thibaud. After comparing the input/output you sent me in the great custom test cases tool, I saw that my solution had some bugs in some cases.
my function should have return an array with each letter and its value… but in this case it returns the array with an additional unexpected value with index “” (empty string) . So after some debugging I managed to find the solution and reached the so coveted 100%.
Thank you again Thibaud. and thanks to Kirbiby too.
A last question… How can I set this topic as resolved/solved?
Sorry I am really new in the forum and topics world, I am not a great user. Usually I look for the solution by myself or read the existing topics but for this one I really needed your help guys and it was very useful.