Skip to content

triangle exercise based on fallacy #798

@splace

Description

@splace

the problem is hard to explain, but...

to always be able to determining if a triangle is equilateral requires infinite precision because its a euclidean definition, and computers cannot do that.

this general misunderstanding produces a lot of bugs in code.

understanding why this is, is a fundamental principle see; https://en.wikipedia.org/wiki/Floating-point_arithmetic#Accuracy_problems

in the example the test input coordinates have limited precision so it can work, but it gives people a false idea, that it will always work, its a incorrect concept that teaching examples shouldn't be re-enforcing.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions