Skip to content

Incorrect solutions #1

@Aimnos

Description

@Aimnos

After testing a lot, I found out the inputs for all the Fare 'TestCase's:
TestCase#0 - input: 1 2 3 5; expected output: 14
TestCase#1 - input: 3 2 10 2; expected output: 4 (should be 2)
TestCase#2 - input: 1 2 3 4; expected output: 11

The problem is that the expected output is completely incoherent to the input, at least as I understand the problem.
Reflecting that, I implemented a solution that correctly prints 4 on TestCase#1, but is incorrect in a more general scenario.
To anyone that can explain to me why it is the way it is, please do so.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions