Skip to content

Model solution for minContainingHexagon in lesson8.task1 is incorrect #89

Description

@AbdullinAM

Some test cases:

val pts = "-557.-557, 617.-557, -558.-999, -107.-965, -1000.-483, -557.-1000, -557.-558".split(", ").map {
    val (first, second) = it.split(".")
    HexPoint(first.toInt(), second.toInt())
}.toTypedArray()

Model solution gives a hexagon with radius 1030. But in fact there is possible to build a hexagon with radius 809 and center (-556.-192), that will satisfy the task condition.

More examples:

[-741.-558, 465.-329, 520.-1000, 347.-1000, -433.-557, -668.-558, 20.-57, -558.591, -74.-558, -999.-557, 455.-286, -558.-1000, -81.-557, -595.-557, -557.-153, -557.523]
Best solution r=890, model solution r=925

[-557.-557, -266.-1000, -518.-1000, -999.-999, -999.-325, -1000.582]
Best solution r=791, model solution r=916

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

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