Ad
  • Custom User Avatar
  • Custom User Avatar

    @Sejiko

    donaldsebleung is a well known user of the site and of the few I just checked, he is the original PHP translator of the kata given. He hasn't cheated, in fact he has honorably created new content on the site for others to train on. Please email me your cheat technnique so that I can verify if its new or not.

  • Custom User Avatar

    Extra note to all: Although not documented on this page (or anywhere on Codewars), the current policy is that if the site maintainer (i.e. @jhoffner) discovers anyone cheating and/or plagiarizing in any manner (e.g. runner cheats, rampant plagiarism through use of an alt account or through Googling "released" solutions by other Codewarriors), the offender will immediately be banned from using Codewars for an indefinite period of time, his/her rank will be reset to 8 kyu / 0% and his/her honor will be reset to 0. So whatever you do, don't cheat (it doesn't benefit anyone in the first place anyway - what fun is there to "pass" a Kata without actually solving it?) ;)

  • Custom User Avatar

    @Sejiko,

    Instead of accusing me in public without my knowledge based on your faulty assumptions, perhaps you could have directly emailed @jhoffner (maintainer of this site) in private regarding suspicions about a potentially cheating user? What you just did on this thread was highly dishonorable regardless of whether your claim is true or not because I did not receive any notification from conversations in this thread so I was not given a chance to publicly defend myself against your accusations which is what some would call "backstabbing". I sincerely hope such an incident would not happen next time.

    Furthermore, I have more than substantial evidence that I am innocent of cheating, at the very least in the PHP version of the "Find the unknown digits (4 kyu)" Kata. The only reason my one and only submitted PHP solution to that Kata is 100% identical to the reference solution used in the random tests is because I was the PHP translator to that Kata; hence, I would naturally use my own "Complete Solution" as the reference solution to validate against the user solution in the random tests. If you do not believe what I am saying, just click the "Add Translations" button on that Kata, scroll down to the PHP translation and check the author of that translation.

    However, seeing as you also submitted exactly one PHP solution to that exact same Kata which is identical to my submitted solution (minus a trailing newline or two), I'm starting to wonder if you utilized the cheat yourself and unfairly gained honor and rank progress from it as a result. For the moment, I'll assume the better of you which is that you forfeited the PHP version of that Kata, saw my solution and then only copied, pasted and submitted my final solution afterwards which would mean that you did not gain anything from it.

    Signed,
    @donaldsebleung

  • Custom User Avatar
  • Custom User Avatar

    You mean hardcoding return results? That's not called cheating, that's just kata tests being bad and lacks in random tests.

  • Custom User Avatar

    Its true,writing unnamed function is slighty faster but code is a little messy after.
    If function is really simple like multiply example its good place for unnamed functions,when you know that you will not use it again.
    In JS alot of people use unnamed functions in sorting arrays too.

    Its good to have more options how to pass/write functions :)

  • Custom User Avatar

    Glad you're enjoying my Kata Series :D

    As discussed in the Lesson in this Kata, various advantages of interfaces include:

    • Unlike (parent) classes where a child class can only inherit from one parent class, a class can implement multiple interfaces so that two different classes can share similar methods and behaviour yet have other different properties, methods and behaviour
    • In large project where a large number of interrelated classes are present, interfaces can ensure that certain methods common to multiple classes have the exact same argument list so when you use a method of the same name from different classes, you do not have to worry about passing in different types of arguments or passing in the arguments in a different order depending on the instance of the class that the object belongs to - this makes editing your code easier as you are less likely to make mistakes when/if you change an object from being an instance of a class to being an instance of another (closely) related class
    • Another major advantage of interfaces is realised when you are working on a PHP project involving multiple classes as a team of developers. By defining certain interfaces and requiring your colleagues to implement certain interfaces when they program the classes, it ensures that in the future when the classes are complete and when you use an instance of one of the classes, you automatically know the order and nature of the argument list of certain methods which again reduces the number of mistakes in collaboration.

    That being said, if you are working on a small PHP project by yourself which involves only one or two classes, it is unnecessary and indeed bad practice to define interfaces for those classes to implement.

    Hope this answers your question :D

  • Default User Avatar

    If you print too much, it may happen in certain cases. I already accidentally passed too katas with wrong solutions while trying to debug.

  • Default User Avatar

    Try without using a factorial function.