Ad
  • Custom User Avatar

    I've stored args in a scoped array. Different wrappings start to reference the same array. A test case not working with my "shared state" solution:

    const add3argsTo1        = curryPartial((a,b,c,d) => a+b+c+d)(1) // [] <- args array state at call
    const add2argsTo1And2    = add3argsTo1(2) // [1]
    const sumOf1And2And3And4 = add2argsTo1And2(3)(4) // [1,2]
    const sumOf1And2And8And9 = add2argsTo1And2(8)(9) // [1,2,3] or [1,2,3,4]
    

    A pure solution may be even shorter/easier than an impure one

  • Custom User Avatar

    This is a debugging kata where the goal is to fix the incorrect initial code. This is intended and not a kata issue.

  • Custom User Avatar

    Ranks can't be changed!

  • Custom User Avatar

    You have to add a 'saySetup' and 'sayPunchLine' methods to the object of your result. So that e.g. result.saySetup() returns the corrent answer.

  • Custom User Avatar

    Tests are running against a valid api endpoint (that is hidden from us).
    What you have to do :

    1. call the Fetch api method using parameter (apiUrl)
    2. this function will return the object which has 2 properties. And these properties have function definition (logic to get the jokeounch line...)
    3. real api call is hidden from us, so you have to visualize the data using data sample given to us.