https://www.codingame.com/training/medium/10101
Send your feedback or ask for help here!
Hi and thanks for the puzzle. I must have misunderstood something. On paper, it looks to me like testcase 4 should give a result of 6 (5 rows + 1 column) after adding 3 squares. Testcase 4 shows an output of 3.
Please help me understand this. It did seem easy…
Thanks!
You must find the maximum number of rows and columns being filled by adding 1 square.
In testcase 4, there are 3 possible spots, the first one allows to complete 1 row, the second one completes 2 rows and the third one fils 2 rows and one column.
Your total count is 6, but the maximum is 3.
My bad.
Clearly, I was counting the total number, not the maximum.
I thought I read the specification carefully…
Thank you very much!
i have passed all test bu the score still at 75% , how can i know the stretch test that fails each time after submiting
Try testing your code by creating a custom case where width is smaller than height.