8
retoor
44d

Currently making a perfect sudoku webapp / plugin using native JS and html templates where I'm very enthousiast about.

It allows to select multiple cells and then put in a number and all selected have that number. It keeps state of every change, you can do unlimited redo's. Right click or double click someehere removes selection. Not built yet, but it will have a box where you can paste sudoku's you've found on the internet. I just parse 81 times [1-9] with regex. So all formats are supported including noisy ones as long the noise is not numbers. Making your own puzzle is very easy. Art is to make hard ones. I'm generating extra hard puzzles using C threading. For reference: there are 6,670,903,752,021,072,936,960 sudoku puzzles possible and from that I try to resolve the hard ones using simple human logging with brute forcing as fallback until it can use logic again. 30 million attempts to solve per secon. I should at some more logic. I don't do xwing or ywing, bs imho. You have to be a superhuman to spot xwing / ywing possibilities. I think i can imagine a better logic myself. We'll see.

And yes, that's a real screenshot. Puzzle is validated and it found issues. Marked with red font. Green is current selection by user

Comments
  • 1
    The UX is not my own design. It's how common sudoku apps work that people on YouTube use. Very intuitive with adding small digits in the corner of cells so you can remember possibilities
  • 4
    no, that's not a "screenshot". that's a photo of a screen, and you should be ashamed for it ;)
  • 2
    @tosensei I have no shame, didn't see my profile?
  • 2
    @tosensei it's a long time you upvoted smth. Start with this rant. You'll feel better, I promise
  • 2
    @retoor i upvote when i see something worthy of upvoting.
  • 1
    Nice! Next up: pure HTML
  • 1
  • 1
    I’ve done similar things before, not sudoku. Very satisfying and fun projects!
  • -1
    @tosensei I do often upvote your stuff because with my 1.50cm I'm still a bigger man than you are! 😊
  • 1
    @retoor if you say so~~~
  • 1
    I typed almost only C last few months. Spend weeks on a Regex interpreter from scratch (didn't do research up front, reinvented the wheel to keep it fun) and now in JS, a full featured application. I have a great feeling of completion. My C applications do many times bare minimum and are lot of code. This was just a few hundred lines and built everything I wanted to. But I know it gets boring quick. Sounds weird, but I like to do the much typing you do in C. Rakketakketak! Keyboard sounds like an AK47. Result: moving a string within a string. Jay.. :p. Note about that: that's impossible in C in exception of malloc'd the source string big enough to also use a destination string and pass it with **. So you should kinda know the replace text length upfront if it's longer than text to replace. Other way is to return a new malloc'd string with the changes. Compare that with js
Add Comment