• Sign Up
  • Kata
  • Kumite
  • Blog
  • Forum
  • Wiki
  • Leaders
  • Log In
  • Sign Up
Name:Abram Gornik
Clan:AwesomeIncBootcampS21
Member Since:Dec 2019
Last Seen:Apr 2021
Profiles:
Following:48
Followers:48
Allies:48
View Profile Badges
  • Stats
  • Kata
  • Collections
  • Kumite
  • Social
  • Discourse
  • Conversations
  • Replies
  • Authored (20)
  • Needs Resolution
    • abramgornik
    • commented on "Sliding Puzzle Solver" kata

    Greatly enjoyed solving this. Thanks for making it!

    But I do want to bemoan the choice to have the zero tile in the bottom right rather than the top left, haha.

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    Done. Thanks!

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    Fixed.

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    Oops, forgot to port that over.

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    I think that fixed it. Try again!

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    Ok, the randomized tests are now scrambled versions of a solved board.

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    Interesting. I'm going to change how the random boards are created and then get back to this.

    Also, any feedback on better wording for the instructions is welcome.

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    I'm assuming that was the case.

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    Certainly not. Unless I did something incorrectly, its still possible for the random board function to return a solved board, it's just significantly unlikely.

    I will refactor it to just scrambling a correct board.

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    Good to know about logging. I didn't know it would output if failed. I had run into a few kata that didn't seem to do that, which was frustrating. I removed the logs.

    No. Just let expects = solvedCheck(testBoard);

    Oops. Fixed.

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    Did you mix this up with the minimum value for N ?

    You're exactly right. Fixed!

    (and the second sample tests has two threes and no two)

    In my mind, this is still an unsolved puzzle, but I can certainly change it.

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    Ok, done!

    ...
    let testBoard = Math.floor(Math.random() * 4) ? mkRandBoard(size) : mkSolvedBoard(size);
    ...
    

    Thanks for your help. If you have time and can offer some clarity on the remaining issue left by FArekkusu, I would appreciate it. :)

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    Oh. What if I make it 50/50 that each random test will expect true? Is that what you're looking for?

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    Ah ok. I'm not sure how to implement a random test that garauntees at least some results that expect true. If I have to make them completely random, then the chance of that is just going to be very small.

    • abramgornik
    • commented on "Sliding Puzzle Verification" kata

    I apologize if I'm misunderstanding.

    If the issue is that there are no random tests that will expect true, then I think no adjustments are necessary. The first section of tests are random sizes that expect true.

  • Loading more items...
  • © 2021 Codewars
  • About
  • API
  • Blog
  • Privacy
  • Terms
  • Contact
  • powered by

Confirm

  • Cancel
  • Confirm