Ad
  • Custom User Avatar

    This code doesn't work in all cases. I copied it and pasted it to VS Code and tried it with a test polynomial I made up.

    poly = '2ac+8ca+9poy-21opy'

    The answer should be 10ac-12opy but it returns 0ac-2opy.

    The problem has to do with replacing the 1 with an empty string in the return line.

  • Custom User Avatar

    In the kata desciption, it's unclear whether the result is supposed to the sales id or the department id.

  • Custom User Avatar

    The image links in the kata are broken.

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    For this and other SQL kata, is it possible to download the databases so I can play around with solutions locally on my laptop? If so, how can I download them?

  • Custom User Avatar

    I figured out the issue in that my code would work when the there wasn't enough money to buy all the gifts but not when there was money left over. I think this kata would be improved if the latter situation was put in the "Attempt."

  • Custom User Avatar

    I pass all the 100+ tests except for three, and I can't figure out why. These are the three I fail:

    should return all gifts (12)
    Expected: 12, instead got: [5, 5, 5, 5, 5, 5, 10, 10, 10, 10, 10, 10]
    should return all gifts (4)
    Expected: 4, instead got: [1, 1, 1, 1]
    should return all gifts (56)
    Expected: 56, instead got: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]