Earn extra honor and gain new allies!
Honor is earned for each new codewarrior who joins.
Learn more
  • Solved in seconds due to obvious, syntactic reasons, no thanks to the rather lacking description, mind you. Why try for "amend" when the simple "mend" would amply suffice? Do you think you're Oxford's Digest or something?

  • The "actual" tests are under the Submit button.

    Yes, you must write your own example tests. This is not an issue.

  • Hi ~ this word does not allow one to "make just any changes" and it certainly does not only mean "to add to". It is specifically inclined towards improvement, exacty such as you would expect in a bugfix kata. Meanwhile, this would be a better word instead:

    emend |iˈmend|
    verb [ with obj. ]
    make corrections and improvements to (a text).
    • alter (something) in such a way as to correct it
    

    Beyond that one word, and keeping in mind bugfix kata often rely on TDD and may be differently structured (note the lack of a direct example of a correct answer in the sample tests), I would honestly like to know what your precise wording for the description of this kata ought to be without giving away the answer, thanks.

  • If you look at the evidence, all the comments, then your statement 'the directions are clear' seems to be false. Just adding the definition of one of the words to a reply doesn't prove the directions are clear. Actually, you CAN'T even make just any changes (the definition you provided for amend) to the text in this kata - you must keep the exact words. One of the comments defined amend to ONLY add to the text, which I guess would make it clearer (provided that is the definition in your head)... But then that's the point, context and clarity in communication isn't just using what YOU think is clear, it's using what provides clarity to the hearer/reader. I'm guessing with the attitude of 'this is clear, look at the definition of this word', a software developer can make some pretty useless programs and always blame it on the user requests or on user error :)

  • the directions are clear: Can you amend this object so that its properties comprise only vaild identifiers?

    amend
    [əˈmend]
    VERB
    make minor changes in (a text) in order to make it fairer, more accurate, or more up-to-date.
    
  • This comment is hidden because it contains spoiler information about the solution

  • You should define that identifiers names can't be changed... unaccurate and consufing just because of that, but also a nice excercise anyway :)!

  • The Python tests will still try to use the dictionary if the keys don't match, which results in a non-deterministic comparison (in Python 3.4 used by codewars). There's about a 1 in 32 chance the order comes out right - I hit that accidentally, once.

  • This was the most frustrating kyu 8 problem because of the poor problem description and confusing Python test output. The entire problem description is one line:
    "Can you amend this object so that its properties comprise only vaild identifiers?"

    "to amend" is to add to. We are changing the object, not adding to it.
    In programming languages, "valid identifiers" refers to allowed variable names. It has nothing to do with this problem.
    I would even argue that "dictionary keys" is a better term than "properties", since properties are things like the dictionaries size or capacity.

    Normally some tests are random, but the Python tests for this problem are random on accident. Codewars uses Python 3.4, which does not define the order in which keys are retrieved from a dictionary. This test takes the first key it finds, and compares it to the first result. That is non-deterministic behavior, and results in non-deterministic error messages. A random key in the dictionary is flagged as being incorrect.

    The tests should check that the dictionary names exactly match the intended names. The problem description should state that the keys of the dictionary must remain the same, but be valid.

  • Hi! Thanks for the Kata.

    question: why link to the object literal named with capital letter Person? This is not a constructor.

  • Where is actual JS tests??? I must write my own tests for this kata??

  • Thank you for your suggestion.

    Labeling this as an issue is a bit on the heavyhanded side.

    Closing.

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

  • Loading more items...