Ad
  • Custom User Avatar
  • Custom User Avatar

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

  • Custom User Avatar

    Just thinking that "loop the same long string 26 times" already is O(n).

  • Custom User Avatar

    This is actually an issue because I didn't know what the hell fizzbuzz is

  • Default User Avatar

    You simply didint provide any directions on thi assuming that 'its one of the first programming puzzles people learn'
    Lame description.

  • Custom User Avatar

    Start from the first kata in series if this one is too hard for you

  • Default User Avatar

    pinging you to note that there's a new php issue. your regex is no good. woahh a regex bug? that never happens.

  • Default User Avatar

    Hello. Unless I am missing something obvious, there seems to be an issue with random tests in PHP.

    I keep failing with messages like:

    1. Fight: dpabzgm**dy*s
      Expected result: Let's fight again!

      OR

    2. Fight: *ddq*bpxzb**m
      Expected result: Right side wins!

      OR

    3. Fight: up**sz
      Expected result: Let's fight again!

    None of the above expectations is correct! (according to how I understood the kata details)

    Here is my analysis of the above examples:

    Example: fight string: Test expects: fight string after airstrike: Left side letters: Right side letters: Left power: Right power: Correct result:
    1 dpabzgm**dy*s Let's fight again! dpabzg_______ 'p','b' 'd','z' 5 3 Left side wins!
    2 *ddq*bpxzb**m Right side wins! __d___pxz____ 'p' 'd','z' 3 3 Let's fight again!
    3 up**sz Let's fight again! u____z - z 0 1 Right side wins!

    Can someone please check the random tests setup or point out my mistake? Thank you very much in advance.

  • Default User Avatar

    The description is not good. it does not make explicit how to calculate who wins, you have to only assume that.

  • Custom User Avatar

    A problem with your code is not a kata suggestion, it's a question. Please read this: https://docs.codewars.com/training/troubleshooting/#expected-the-same

    Also:

    Write a function that takes in a string of one or more words, and returns the same string...

    Your code always returns None.

  • Custom User Avatar

    BF:

    '\u0000' (charcode 0) isn't the same as the character '0' (charcode 48). Can you find a way to map charcodes 0 - 9 to the actual characters '0'-'9'?

    (Not a kata issue by the way)

  • Custom User Avatar

    No, the example is fine. the 3 in 13 is to be considered a 7 and it becomes a 17, that's why ordered ascending the expected result is [12, 14, 13]. 3 means 7 in that other planet, but you shouldn't translate to your own language, so, no, the answer is not [12, 17, 14]. Nothing to fix, not a kata issue.

  • Default User Avatar

    poor description and confusing examples.

    this is not right: [12,13,14] -> [12,14,13]
    it should be: [12, 17, 14] if 3 in 13 is to be considred
    or no change to be made: [12,13,14] since there is no 3 or 7

    Please be fix it either your requirements or your example and tests

  • Default User Avatar

    not a kata issue, works fine in ruby, and you have passed the kata anyway

  • Default User Avatar

    Im getting this error.

    `createPhoneNumber': wrong number of arguments (given 0, expected 1) (ArgumentError)

  • Loading more items...