Giter Club home page Giter Club logo

sudoku's Issues

When creating full 4x4 sudokus, sometimes invalid sudokus are created and sometimes an AssertionError is thrown...

Expected Behavior

Creator.createFull(GameSchemas.SCHEMA_4X4)

should return a valid 4x4 Sudoku.

Actual Behavior

Creator.createFull(GameSchemas.SCHEMA_4X4)

(1) returns an invalid Sudoku:
Example in Kotlin:
invalid sudoku


Creator.createFull(GameSchemas.SCHEMA_4X4)

(2) throws an AssertionError:
Example in Java:
Arguments: -t -e Both -s S4x4
JVM-Options: -ea
assertion error

Steps to Reproduce the Problem

  1. Enable AssertionErrors in JVM-Options -> -ea
  2. Call Creator.createFull(GameSchemas.SCHEMA_4X4) multiple times.

Feature Request: Set Riddle Difficulty

Really great and fast library!
However it would be great if the riddles difficulty could be defined when creating a new riddle.
I would imagine this could be implemented by solving it partially depending on the set difficulty.

Unable to serialize/deserialize Riddles

Hi @sfuhrm ,

I've been trying to use your library to build my own webbased game as a personal learning project, and I'm impressed by your library! Very cool!

One thing I'm struggeling with, is saving and loading riddles to resume later. I can save a Riddle to a file and load it with the sample code you have built in the sudoku client: https://github.com/sfuhrm/sudoku/blob/master/sudoku-client/src/main/java/de/sfuhrm/sudoku/client/Client.java#L160

But this will always solve the riddle, and not provide me with a reuseable Riddle.
A GameMatrix instantiated with the data will always give the same solution, but not always the same Riddle if we use: https://github.com/sfuhrm/sudoku/blob/master/sudoku/src/main/java/de/sfuhrm/sudoku/Creator.java#L297

TL;DR; Is there a way to instantiate a Riddle with given data?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.