Skip to content

Sowmith-Reddy164/Smart-dot-Game_backtracking

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

Smart Dot Game with Randomized Backtracking

Description

The Smart Dot Game is a grid-based puzzle game built using Python and Tkinter. It uses randomized backtracking to generate the puzzle. Players must uncover hidden dots on a grid using row and column clues, testing their logic and deduction skills.

Features

  • Randomized Puzzle Generation: Dots are hidden on the grid with constraints, ensuring a unique challenge every time.
  • Clue System: Each row and column displays the total number of hidden dots, providing guidance for solving the puzzle.
  • Interactive Gameplay:
    • Click cells to uncover dots.
    • Win or lose messages based on performance.
  • Solution Display: Reveal all hidden dots if you're stuck.
  • Reset Game: Start a fresh game anytime.

Prerequisites

  • Python 3.x
  • Tkinter library (comes pre-installed with Python)

How to Run

  1. Save the script as smart_dot_game.py.
  2. Run the script using Python:
    python smart_dot_game.py

How to Play

  1. The game starts with a grid and clues for each row and column.
  2. Click on cells to guess the locations of the hidden dots.
  3. If you uncover all the hidden dots, you win!
  4. Clicking an incorrect cell results in a loss.
  5. Use the "Show Solution" button to reveal the solution, or click "Reset" to restart the game.

Code Highlights

  • Randomized Backtracking:
    • Ensures that the placement of dots satisfies the clue constraints.
  • Tkinter for GUI:
    • Provides an interactive interface with clickable grid buttons, clue labels, and action buttons.
  • Dynamic Clues:
    • Clues are dynamically generated to match the hidden dots.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages