Ad
  • Custom User Avatar

    The performance requirements are really high, I would rank it closer to a 2 kyu then a 3 kyu.
    Good luck for other trying to solve it, if it timeout at the very end it is normal, try to keep optimizing your algorithm little by little until it passes.

  • Custom User Avatar
  • Custom User Avatar
  • Custom User Avatar

    Don't it deserve to be a 4 Kyu ?
    Nice Kata however, it brought me back in my old maths :)

  • Custom User Avatar

    There are two mistakes in your code; the first one is that you can't sort something empty, hence you should add a check whether the string is null at the beginning; the second is that your list (sorted) is outside your function, therefore it doesn't reset itself and lead to several errors, you must re-init it at the beginning of your function.

    Have a nice day :)

  • Default User Avatar

    There are moderation issues, there could be someone who just scans the user base and ensures that people who have abilities use them and don't abuse them, but that takes a LOT of time, just think of the size of the user base.

    It is also possible you could have some kind of auto-correction like you noted. But just imagine someone who actually liked raising issues but always did it positively and assisted people in resolving them, and who downvoted people who were abusive. You would not want them to lose abilities.

    If the community is healthy, it will just take care of itself and the best way for this is for the people who want to help and assist others, not let the dominant voice be otherwise.

  • Custom User Avatar

    This kind of interation did happen a number of times with new members, actually, which were treated as retarded while they were just asking junior questions (and I am referring to polite people reading the previous comments and the like).

    And good point for the rest, although some other more technical fix might be also needed, like the system ignoring the feedback from someone who predominantly downvotes users or kata, possibly?

    As for my part, I admit being annoyed in having to spend more time "fixing" a kata than actually creating it, but, yeah, I am quite persistent and I tend to take the better side of things - at least I managed to learn a lot when feedback was given :)

    Edit: lol, that said, as I scrolled up having been notified of more new comments here, I noticed that me and others were downvotes again - well, certainly somebody has a lot of time on his hands...

  • Default User Avatar

    Giacomo, the problem really isn't with you as you are likely to just ignore it, continue solving/making kata's, and your own with the issues will just even out after awhile as other people solve/translate them and the votes are just counter acted.

    The real issue is just imagine that this interaction happened to a new member, there is a real possibility they would not return and not only is CW not a place where they can learn, the sites loses from potential member who could learn and continue to add useful/improved content.

    This can be counter acted by the user base in the same way, assuming there is more of a majority of people who see such interactions as not being productive for the site. They just up vote the person trying to create content, help them along, and try to counterbalance the negativity.

  • Custom User Avatar

    The mention in the kata description is just to suggest not to go for a really brute-force-based approach (unlike yours, which is just inefficient), which would be something like finding minimum and maximum, creating a huge array of zeroes, etc, for example; or comparing dates with some quadratic approach.

    I think you mentioned that testing is luck based, in your own perspective, so that might be the case? Also, consider I just refactored the ranges to be harder on users who actually go and compute each single year: did you retry all languages recently?

  • Custom User Avatar

    Are you getting any errors due to them?

    Actually I do, when I copy snippets from CW editor and paste them into my Visual Studio. And I think "code template" is just an implementation of CW, I sometimes create separate files in my project for each snippet, as I believe it should be actually seen this way. And then compilation fails, however it can (should?) be prevented by placing required includes in each code file/snippet.

  • Custom User Avatar

    Actually it does not matter. C++ standard requires each class to have corresponding include file included, and if you do not add it, you risk that when environment gets updated, your katas stop to compile.

    It is a common 'problem' with C++, that one header file includes and implicitly provides other ones, but it is undefined and should never be relied on. Let me quote myself on this ;).

  • Custom User Avatar
    1. At the moment of publishing your kata was a mess with performance requirements all over the place.
    2. What you're calling "issue fixed" is an outright lie: performance is no more mentioned in the title - but it IS mentioned in the kata description, and the tests STILL indicate that performance should be considered.
    3. The fact that my brute-force solutions still passes in 3 languages out of 4 I've tried either means that either the tests in Python/JS/Ruby are trash because they are too light, or the tests are trash in C++ because they're too intensive.
    4. And before your "fix" it wasn't me saying your solution was inefficient - it was your own test suite which my brute-force solution managed to pass in 4-5 seconds, and your solution managed to pass in 8-10 sec (in 3 different languages).

    The fact that you call people out for "badmouthing you and your kata" because they're raising issues, and then twist their words to make it look like you're the victim is a joke, and only shows how much of an ass you are. If dealing with other people and issues they raise is that much of a hassle for you, then the obvious question is - why are creating katas if you don't give a fuck about any opinion which is not identical to yours?

  • Custom User Avatar

    I got your point, but can a user really counter that, as I was considering? Say I create a new one and gets exactly the same treatment, which does not seem that unlikely: what's next?

  • Custom User Avatar

    IIRC <iostream> and several other includes are provided by the CW system, while the <vector> library is on top of the code template, isn't it?

    Are you getting any errors due to them?

  • Custom User Avatar

    I have not solved the kata yet, but I noticed with initial setup and sample tests that some includes are missing: utility for pair, vector in sample tests, etc. While it might be not-an-issue since these two snippets are expected to be filled by submitter, I strongly suspects some headers are missing also in main test suite and reference solution. Are they?

  • Loading more items...