Ad
  • Custom User Avatar

    I haven't laughed this hard reading code for a long time... and this time for the right reason :)

  • Custom User Avatar

    This is a very clever way of adding the multiples of 3 and 5 without repeating the common multiple. However I can't mark it as a best practice because it forces a traverse through all of the natural number (minus 1). If we're talking about a small input number it's negligeble, but if we're talking about a very high input number then it starts to take a toll.