RSDK or R SuDoKu is an R package developed for the project of R programming in the master 1 SSD (Statistiques et sciences des donnés),faculty of science Montpellier.
The package contains a shiny application that we can play sudoku on it.

For a full documentation : https://CRAN.R-project.org/package=RSDK

Install RSDK

You can install the package from the CRAN by runing directly in your console:


Or use the installation of the package from github, so:


After installation of package, are you ready to play?

launch R SuDoKu

For playing in the shiny application all you need it’s to load the RSDK package, and call runSudoku() function, run the following in the console:


How to play in RSDK

After launching the application:

How difficulties levels are defined in the game ?

What is backtracking algorithm?


The function bt_solver() in the package use the algorithm of backtracking to solve the incomplete sudoku grid, and it returns a list of two element the first one contains the solved grid, and the second one contains the number of the backtracking, that the function did to solve the grid. So the difficulty of each grid is associated to the number of backtracking that the function bt_solver did on the resolution of the grid. For optimization issues we’ve we have choose the median of an array of the number of backtracking for 100 incomplete grids of the number of gaps, for example we’ve choose 45 gaps for the “Easy” level,48 gaps for the “Difficult” level, 51 gaps for the “Hard” level and “54” gaps for the “Legend” level. And the difficulties are as follow:


Released under MIT by [@ELKHMISSI](https://github.com/ELKHMISSI).