Ad
  • Custom User Avatar

    +1 Clever Point for checking perfect squre differently than multiplying with the same number.

  • Custom User Avatar

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

  • Custom User Avatar

    I massively overcomplicated this, as I misinterpretted the problem.
    We know intuitively what each node's value will be - if we need to step forwards 5 steps, we know what the next value will be.
    We do not need to visit each node, and step over them one at a time.

    The problem I've solved here, is having a ring of people's names, which you can't know in advanced, because they're not sequential and predictable.
    But also an array might have been better anyway. Only problem with an array is the performance cost assosciated with removing at a random location, compared with linked list.

  • Custom User Avatar

    this was mine. Really quite inefficient (lots of removing from start of array). But working with strings like this has also got to be suboptimal. Should've probably broken into a few more functions. But it does the job, in a semi-readable way. But took ages, lots of googling to understand how base64 actually works. Interesting though! Enjoyed this

  • Custom User Avatar

    You're performing the Math.sqrt(sq) function twice, it would have been better to put that into a variable. Just to save yourself from calculating it twice. Clean solution though.

  • Custom User Avatar