Ad
  • Custom User Avatar

    "Left of" clues mean that s1 is in any column that is to the left of the colum s3 is in. (I hadn't noticed the example didn't make that clear as both left of clues are to the immediate left, but that is not a constraint). In other words, using A < Q and given that Q is in column 4, then A may be in columns 0,1,2, or 3.

    "Next to" clues mean that the two object are in columns that are directly next to each other. So in the case of AQA and given Q is in column 2, then A must be in column 1 or 3.

  • Custom User Avatar

    If October 23, 2019 was Rebo Wage (Note you have it spelled Rebu in the description) then wouldn't October 22, 2019 (the day before) be Selasa Pon (1 earlier on bothe lists)?

    If so, then the sample tests are wrong:

    assertEquals("Selasa Kliwon", Weton.getWeton("October 22, 2019"));
    
  • Custom User Avatar

    In your description you say:

    If a player has no clubs, no hearts, and no diamonds, then the player must play a spade, and will be guaranteed to win the trick

    But then in your sample and sample tests you say that the "2S" has a winning probability of 0.

    I feel like I must be missing something. I'm not familiar with Spades so maybe its something there, or I may just be missing something else.

  • Custom User Avatar

    the 5 card straight (7-8-9-10-11) exists in those 7 cards.

  • Custom User Avatar

    I'm a bit unsure of whether my code has an issue (entirely possible, I admit) or if there is and issue with the java tests. I am getting a good number of "unknown symbol" errors.
    Examples:

    ./src/test/java/SolutionTest.java:109: error: cannot find symbol
    	private BigInteger calculateLengthSolution(String cable) throws BracketException, NodeException{
    	                                                                ^
      symbol:   class BracketException
      location: class SolutionTest
    ./src/test/java/SolutionTest.java:109: error: cannot find symbol
    	private BigInteger calculateLengthSolution(String cable) throws BracketException, NodeException{
    	                                                                                  ^
      symbol:   class NodeException
      location: class SolutionTest
    

    It is entirely possible the issue is on my end, but it looks to me like the test solution class cannot see the BracketException and NodeException classes I created as static classes inside the Cable class, which makes sense. But I'm not sure how/if I can correct this on the test solution side.

  • Custom User Avatar

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

  • Custom User Avatar

    Thanks for the suggestion. That process is what I was thinking, and I've implemented it. Currently the kata is configured to test 40,000 games which seems to be enough (when I tested locally) to throw a wrench into trying the BFS/DFS approach. It appears to have invalidated the previously accepted solution by hobovsky. Thanks for the help on this, my first, kata. I also decided to leave the static method alone for now as I do like leaving it up to the user to decide how they want to tackle to problem. Thanks again (and let me know if you have any other suggestions)!

  • Custom User Avatar

    Sorry, not sure I'm understanding here. Are you suggesting that I randomly reassign the characters in the clues and suggestions for each row?:

        A <-> E    B <-> D
        F <-> J    H <-> I
        L <-> N    O <-> K
        S <-> P    R <-> Q
    

    Or are you suggesting I create a randomized final board (shuffled final state) and then build clues based on that board?

    Thanks for your help in undersatnding here

  • Custom User Avatar

    I think that makes sense to me. Increase the number of tests, perhaps by randomizing the order of clues within a test and repeating each test (with shuffled clues) some number of times? I'll play around with that.

    Also, you previously suggested changing the solution to one of a constructor/method rather than a static method. I'll get to working on that as well, but this is my first published kata, is it generally considered cool to make that sort of change that would invalidate previous solutions so broadly?

    I'll take a look at making those changes today.

  • Custom User Avatar

    Thanks for the suggestion. I originally toyed with the idea of using a constructor and method, and looking back I can't remember why I opted to do it as I did. I can't think of a good reason to keep it the way it is now, so I'll refactor to reflect that. I'll try to get to it ASAP. Thanks again.

  • Custom User Avatar

    I've added these cases into the sample tests. Thanks for the suggestion.

  • Custom User Avatar

    Thanks for the kata, but some things appear quite wrong.

    • Your sample tests appear to be broken.
    • Just in testing the "attempt" solution checker to see what you're testing I noted that for S:40 D:2 H:6 you accept "TCTCTB" (I took this from one of your broken sample tests). With that solution the gooble will have only carried 80+160=240 kg. And, I don't think per your rules it makes much sense to ever have a T as the second to last entry either.
    • I also saw your random tests started with a list of several hundred tests with S=0. This is practically useless.
    • You might want to clarify that multiple solutions exist for some scenarios and be able to handle them all or specify some metric that would cause one to be chosen from the pack. (Ex. "TCTTCB" & "TCTCCB" are both valid solutions as currently written).
  • Custom User Avatar

    Java random tests seem to be messed up. When I take a look at the input it looks like they are formatted with a digit instead of an underscore. Not aproblem to work around, but wanted to point it out.

  • Custom User Avatar

    Thanks for the clarification. I was probably just overthinking it. Thanks for the kata.

  • Custom User Avatar

    I might be thinking about this incorrectly... How would the true/false sequence work for the real world situation of a shot which lands in correctly, but is not returned (opponent doesn't get a raquet on it). In other words if P1 serves, it lands in, but P2 doesn't get a raquet on it, then in the sequence is there a corresponding F (even though there was never a ball that landed out?).

    I see the caveat for the last ball in the sequence, but I just wanted to clarify that an untouched good shot would still be a T and F sequence even if there was no return (in the real world).

    Example For series T / T / F it seems like it could be interpreted as each of these unless a false is always present after shots which land correctly but are not returned:
      1) p1 good serve, p2 good return, p1 bad return ---> p1:0 - p2:15
      2) p1 good serve with no return, p1 good serve, p2 bad return ---> p1:30 - p2:0
      3) p1 good serve with no return, p1 good serve with no return, p1 bad serve(fault) --> p1:30 - p2:0 (p1 on second serve)
      4) p1 good serve, p2 good return of serve with no return by p1, p1 bad serve(fault) --> p1:0 - p2:15 (p1 on second serve)
    

    Hopefully that makes sense, and we can assume scenario 1 is as intended? And as I type this, just wanted to clarify when you say "all the balls the players have hit and whether they landed in or out", am I to assume that the balls don't actually have to land to be present in the sequence? (ie p1 hits it to p2 who returns it into play before it hits the ground would be T / T). Sorry if I'm being pedantic, just trying to clarify how I'm to think of it.

  • Loading more items...