Ad
  • Default User Avatar

    I guess it's your implementation's problem. I faced the same but changed something in data structure and now it works. I'm sure it's because function composition and matrix multiplication are non-commutative so the order of evalutation should be preserved.

    I didn't have problems with min though.

  • Default User Avatar

    I tried your solution and I get:
    "Expected: equal to 22
    Actual: 16".
    So writing "...if no output to cout or cerr is getting actually written in test reports" is wrong.
    What more do you want?

    BTW you fail the first test "dotest(10, 22);". In this case you have the input, you have "actual", you have "expected" and, in addition, you have the corresponding exemple in the description: "Ex: u = [1, 3, 4, 7, 9, 10, 13, 15, 19, 21, 22, 27, ...]"... so you have everything you need to debug your code.

  • Default User Avatar

    There exist many comments amounting to the same message as yours.
    They are almost all about an incorrect observation. You're going to get an identical answer/reference to existing answers unless you add more information so that it is no longer the same comment as those others.

    If you provide a way to reproduce your observation (your code), others can point out the problem. Better for everyone.

  • Custom User Avatar

    That's because you're reading the logs incorrectly. Take 1 minute and have a look at hundred other comments with similar questions.