Triangle tests don't cover the case where a+b=c (degenerate triangle)

Agree. If we change the instructions, then its only 4 tracks that would need to decide to append or drop tests.

In the case of Anangram, it was virtually all tracks … so that was a bigger deal.

1 Like

It looks like we’ve got some general agreement here. PR is welcome. :)

2 Likes

I went to update C++ … but it doesn’t actually test for degenerate triangles. The triangle_test.cpp has a comment discussing them and says, “we have decided NOT to test [degenerate triangles]”.

abap has a method to check for degenerate triangles in the test code, but, if I’m reading things straight, the tests don’t actually check that case.

Delphi and PHP mention degenerate triangles in the instructions, saying, “Feel free to add your own code/tests to check for degenerate triangles.”

It’s possible other tracks do check for a degenerate triangle, but if they do, they don’t mention the word degenerate and I’m not prepared to comb through 70 other test files. I believe it’s highly probable that no track actually tests for a degenerate triangle.

2 Likes

PR merged. A bunch of tracks now have a monthly job that auto-opens sync PRs on the 15th so I expect this change should propagate automatically by the end of the week.

2 Likes

Great. Thank you!