Mind: Selection gets active after pushing the 'new' button.
The mind bending puzzle of Peg Solitaire is well-known using different board shapes and different amount of holes for placing the pegs. The common mechanics is that a selected peg is capable to jump any directly adjacent single neighbour in straight direction onto a free position. A peg is removed as it gets jumped. The selected peg will end its move just on the first free field behind the peg that gets removed then.
Supported board shapes include
Due to the different shapes of the board in this implementation straight jumps are possible in either two or three directions (either four or six directions if counting forward and backward jumps separately).
In Peg Solitaire you select one of the pegs first. This peg is going to be removed building a starting position.
By jumping the total number of pegs is reduced then. All starting positions of a 15 hole and 21 hole triangular board shape do definitively allow to finally end up with just one peg remaining on optimal strategy. This class of challenges are referred to as single vacancy to single survivor challenges. Other board shapes and sizes have both, some solvable and some unsolvable, starting positions for single vacancy to single survivor, too.
If the single vacancy position matches the position of the survivor the challenge is called a complement challenge. As a tough task you might find out which board shapes and vacancies either do or do not allow a complement challenge.
Each jump reduces the total amount of remaining pegs by one. Depending on the board situation a consecutive series of jumps with same peg could be performed obviously. Such chained jumps (also called sweeps) could be seen as a single move. The question arises to find the best solutions with minimum amount of moves then.
Feel free to find all possible solutions for these different kind of challenges.
Copyright (c) 2016, 2023
@author Oliver Merkel, Merkel(dot) Oliver(at) web(dot) de.
All rights reserved.
Logos, brands, and trademarks belong to their respective owners.
All source code also including code parts written in HMTL, Javascript, CSS is under MIT License.
Copyright (c) 2016, 2023 Oliver Merkel, Merkel(dot) Oliver(at) web(dot)de
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
If not otherwise stated all graphics (independent of its format) are licensed under
Images are licensed under a
Creative Commons Attribution-NonCommercial-ShareAlike 4.0
International License.
The basic concept of removing a peg by jumping over the peg in any Peg Solitaire variant belongs to the public domain due to its age and unknown creator.
Commonly used are square-shaped, cross-shaped, or any triangular Solitaire boards first referenced or dating back even centuries ago.
Anyway one might find additional expired or active claims for patents or other legal protection of related mechanics, too, like utility compartments or specific design patterns beyond the Peg Solitaire itself.
This Peg Solitaire implementation uses unmodified independent code libraries provided by third parties. Since their licenses might vary the corresponding information is externally linked below. Thus these external links will enable you to reproduce any copyright notice, any related list of conditions, disclaimers, and especially the copyright holders and authors of the corresponding third party functionality.
jQuery: MIT jQuery UI: MIT Snap.svg: Apache License V2.0