Ad
  • Custom User Avatar

    it's a (very slightly modified) duplicate of 21 sticks

  • Custom User Avatar

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

  • Custom User Avatar

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

  • Custom User Avatar

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

  • Custom User Avatar

    Random tests sometimes give suboptimal fit:

    Test Failed
      Sleeve side is 24, table side is 186
      Expected: 68
      But was:  69
    

    Table at angle 20.839-20.905 degrees can fit 69 sleeves (layers of width 1, 4, 7, 9, 9, 9, 9, 9, 7, 4, 1).

  • Custom User Avatar

    Tags: puzzle -> geometry

    Level: 7 kyu -> at least 5 kyu

  • Custom User Avatar
    Random №77, side is 56: 26 should equal 25
    

    There is a solution with 26 covers (drawing in progress).

  • Custom User Avatar

    I would like to know if an algorithm has been found that returns ALL valid solutions for long sequences of words (> 20 words).

  • Custom User Avatar

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

  • Custom User Avatar

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

  • Custom User Avatar

    My code still needs to be refactored, but i'm getting time out at the 500 tests all at once. My code seems to work properly finding the answer in less than 17 attempts, but i think testing 500 sequences all at once it's causing the problem. Any hint on how to solve it?

  • Custom User Avatar

    I think there should be at least one testcase with a very big number of shelves, so that solutions that count through would get a TimeOut-Error.
    It is obviously an mathematical problem that should be solved mathematically.

    On the other side, we would not see all those funny solutions that I really enjoy to read :)

  • Custom User Avatar

    Hello, I am having trouble understanding the parameters.
    For the fifth test, the output is supposed to be 'Frank, Tom, Sam'

          |==|  |==|  |==|          
        __|__|__|__|__|__|_         
     __|___________________|___     
    

    |[][][][][][]|xxx
    | F x S x T /
    ~|
    ||______________/~~

    
    Should the water not get into the side of the ship and get to all of the sailors? Or am I missing something? I understand that the top x's should be ignored because they are above the water.
    
  • Custom User Avatar

    In Java, it's a bad practice to mix the main code with the test branch. As most of the time, test libraries (like JUnit) are scoped to the test level, and the main code won't compile.

    A better approach would be to have a separate Helper class in the main branch to give match hints. An instance of the Helper class will be initiated in tests and passed as an argument to tryToGuess method.

    Here is a reference to how it's done on a similar challenge - Guess the number!

  • Custom User Avatar

    May I get some hints here? I am not really getting the way to the solution. Does it envolve more Math functions or how should I approach it?

  • Loading more items...