Defribillators puzzle discussion


#310

But exactly what is the problem?

I tried before with Math.PI(), and didnt pass the test.
I tried too with Math.round(Math.PI,-2) and Math.round(Math.PI,-4); and nothing.

:S


#311

try to print your variable “radians”. And what you obtain as “degrees”.


#312

The variables are ok, for example:
rad: 3.833542
dg: 219.64577718614063

rad: 3.87952263361082
dg: 222.28027343137802

The convert is ok, and i pass the test of coding phase. But when I submit one test is failde.
The most strange thing is, when I quit the round of the pi name, test 2 “complete file” fails when i put round to 4 decimals, test 2 pass but 3 fails.

Pbbly is a round problem, but i have no idea how put the code to pass both test.
Do u have any idea?

If I dont get the solution pbbly i ll change the language.

Thx for ur comments.

PD: sry for my english :confused:


#313

I want to help you without spoiling you the issue. Look at what you convert. And the values of rad and dg. Don’t they seem weird to you?


#314

Lol, I noticed the error (palmface), sometimes is really worse when u think you know the reason of the problem because don’t check carefully the posible silly mistakes in the old code.

Thx for your patient Thibaud, u was a huge help.


#315

Hi everybody,
I can’t get access to the full test file, meaning when I check what’s in the $DEFIB, lines between 21 and 155 are missing.
So I passed the 1st and last test by chance but answers of test 2 and 3 are probably included in those lines.
Did I use the $DEFIB the wrong way ? or is there a supplementary check to use ?

Thanks a lot for your suggestions.


#316

Check the lines themselves, not the indexes which represent nothing. You can check the inputs of IDE tests with the button at the top right of the test cases panel.


#317

Hi _CG_Thibaud,
Thanks for the quick reply.
That’s actually what I did … I think. Working directly on $DEFIB.
When I check on the inputs with the button you mentioned, I see all the lines.
Can’t figure out why I can see some lines and not all of them, especially when I try to debug the $DEFIB itself … :frowning:
Would there be anything to do on $DEFIB before using it ?
Thanks for you help,


#318

ok, sorry, I just understood your “problem”. You can’t see all the lines because it’s truncated by us. The console output has a limit of characters to print.

So your issue is not there but rather with your implementation of the solution. Double check your radian/degree conversion maybe.


#319

hi everyone,
i would like to know why my code passed in all tests but not in one validator. the validator it’s not passing is the ‘single possibility’ , but if a try to run the same code in my computer and try to simulate as if it is receiving all the inputs and only one possibility, it returns the correct answer.

ps. sorry for my bad english. Can I post my code here ? (i’m new in this site and coding )


#320

I sent you the validator you failed in PM. Posting full code is not recommended. It doesn’t help much anyway.


#321

hi, _CG_Thibaud
thanks for the help, with that i undestud that i was making the change of ’ , ’ for ’ . ’ in a kinda lazy way haha


#322

Just curious is this puzzle currently broken? If not probably just me needing to figure out something in the code… but for variable N when I run the “Exact Position Test” it reports 167 defibrillator entries and it states that it expects “Cimetiere Saint-Etienne” as the output. But when I look at the 167 entries from the input that entry is not present.

I thought it might be an output buffer issue which is why I printed N and N matches the number of input lines I receive. And the number of entries I see matches N. But again, Cimetiere Saint-Etienne is not amongst those lines.

Anyone else experiencing this issue at present?


#323

The console debug output is limited in size. So what you’re seeing is truncated.

image
You can check the testcases using the button at the top right of the test cases panel.


#324

Yes, it certainly is working. Found the problem with my code. Thank you for your help.