0

Good morning guys,

I am working on implementation of tideman. Particulary at implementing sort_pairs function. I have written it and tested - and the output seems sorted in a proper way. However - check50 returns it as an error. Any idea what the problem might be?

  1. I extended pair data struct in order to store information about strength of victory.

typedef struct { int winner; int loser; int strength; } pair;

  1. The strength is being updated (correctly), as part add pairs

enter image description here

  1. And a simple sorting argument is implemented as part of sort_pairs enter image description here
0

I have the same situation. I am implementing merge sort and the output for the code seems correct, but check50 is saying sort pairs did not sort pairs correctly.

2
  • 1
    This does not provide an answer to the question. To critique or request clarification from an author, leave a comment below their post. - From Review – MARS May 8 at 14:35
  • This does not really answer the question. If you have a different question, you can ask it by clicking Ask Question. You can also add a bounty to draw more attention to this question once you have enough reputation. - From Review – hotwebmatter May 25 at 11:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .