╔═══════════════════════════════════════════════════════════════════════════╗
║ ║
║ ██████╗ ███████╗ █████╗ ██████╗ ██████╗ ██╗ ██████╗ ║
║ ██╔══██╗██╔════╝██╔══██╗ ██╔══██╗██╔═══██╗ ██║██╔═══██╗ ║
║ ██║ ██║███████╗███████║█████╗██║ ██║██║ ██║ ██║██║ ██║ ║
║ ██║ ██║╚════██║██╔══██║╚════╝██║ ██║██║ ██║██ ██║██║ ██║ ║
║ ██████╔╝███████║██║ ██║ ██████╔╝╚██████╔╝╚█████╔╝╚██████╔╝ ║
║ ╚═════╝ ╚══════╝╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚════╝ ╚═════╝ ║
║ ║
║ 🥋 Your Personal Data Structures & Algorithms Dojo 🥋 ║
║ Train. Test. Track. Triumph. ║
║ ║
╚═══════════════════════════════════════════════════════════════════════════╝
Welcome to your personal coding dojo - a retro-inspired, terminal-based CLI tool that transforms grinding LeetCode-style problems into an immersive, gamified experience. Built for developers who love the aesthetic of 80s computing and the discipline of deliberate practice.
DSA Dojo helps you:
- 📚 Practice 100+ curated DSA problems right from your terminal
- 🧪 Follow test-driven development with built-in test execution
- 📊 Track your progress with beautiful ASCII dashboards
- 🔥 Build daily solving streaks and earn achievements
- 💾 Export your stats in multiple formats (JSON, CSV, Markdown)
No browser tabs. No distractions. Just you, your terminal, and pure problem-solving flow.
- 100+ Curated Problems: Handpicked DSA challenges across arrays, trees, graphs, dynamic programming, and more
- Test-Driven Practice: Generate boilerplate code with test cases, solve with instant feedback
- Multi-Format Output: View results as tables, JSON, CSV, or Markdown
- Smart Filtering: Filter by difficulty, topic, solved status, or pick random challenges
- Progress Tracking: SQLite-backed persistence tracks every solve, attempt, and timestamp
- ASCII Art Dashboards: Beautiful terminal UI with progress bars and stats
- Keyboard-First: Blazing fast CLI with shell completions (bash/zsh/fish)
- Lightweight: Single binary, no dependencies, runs anywhere Go runs
- Offline-First: All data stored locally, practice without internet
- Cobra CLI Framework: Industry-standard command structure
- GORM ORM: Clean database abstractions
- Viper Config: Flexible YAML/JSON configuration
- Watch Mode: Auto-run tests on file save during practice
- Editor Integration: Opens your favorite $EDITOR for solving
# Clone the repository
git clone https://github.com/ak95asb/dsa-dojo.git
cd dsa-dojo
# Build the binary
go build -o dsa
# Move to PATH (optional)
sudo mv dsa /usr/local/bin/
# Verify installation
dsa --versiongo install github.com/ak95asb/dsa-dojo@latestDownload the latest release from Releases page.
# Initialize your workspace (creates ~/.dsa/ directory with database)
dsa init
# List all problems
dsa list
# Filter problems by difficulty
dsa list --difficulty easy
# Get details about a specific problem
dsa show two-sum
# Pick a random problem to solve
dsa random --difficulty medium
# Start solving (generates boilerplate + tests)
dsa solve two-sum
# Run tests for your solution
dsa test two-sum
# Watch mode (auto-run tests on file save)
dsa watch two-sum
# Submit your solution (marks as solved)
dsa submit two-sum
# Check your progress dashboard
dsa status
# Export stats as CSV
dsa status --format csv > my-progress.csv| Command | Description |
|---|---|
dsa list |
List all problems with filters |
dsa show <slug> |
Display problem details with examples |
dsa random |
Pick a random problem |
| Command | Description |
|---|---|
dsa solve <slug> |
Generate boilerplate code and tests |
dsa test <slug> |
Run tests for your solution |
dsa watch <slug> |
Auto-run tests on file changes |
dsa submit <slug> |
Mark problem as solved |
| Command | Description |
|---|---|
dsa status |
View progress dashboard |
dsa export |
Export progress data (JSON/CSV) |
| Command | Description |
|---|---|
dsa config get <key> |
Get config value |
dsa config set <key> <value> |
Set config value |
dsa init |
Initialize workspace |
All commands support --format flag:
--format table(default) - Pretty ASCII tables--format json- Machine-readable JSON--format csv- Spreadsheet-friendly CSV--format markdown- GitHub-friendly Markdown
┌──────────────────────────────────────────────────────────────────────┐
│ ID │ Title │ Difficulty │ Topic │ ✓ │
├──────────────────────────────────────────────────────────────────────┤
│ two-sum │ Two Sum │ Easy │ Arrays │ ✓ │
│ add-two-num │ Add Two Numbers │ Medium │ Linked │ │
│ longest-sub │ Longest Substring │ Medium │ Strings │ ✓ │
└──────────────────────────────────────────────────────────────────────┘
Total: 100 problems (23 solved)
DSA Progress Dashboard
Overall Progress: 23/100 problems solved (23%)
By Difficulty:
┌────────────────────────────────────────────────┐
│ Easy │ 15/38 │ █████████░░░░░░ 39% │
│ Medium │ 6/42 │ ███░░░░░░░░░░░░ 14% │
│ Hard │ 2/20 │ ██░░░░░░░░░░░░░ 10% │
└────────────────────────────────────────────────┘
Recent Activity:
✓ Two Sum (Easy) - 2025-01-14
✓ Valid Parentheses (Easy) - 2025-01-13
✓ Binary Search (Easy) - 2025-01-12
dsa-dojo/
├── cmd/ # Cobra command definitions
│ ├── root.go # Root command and global flags
│ ├── list.go # List problems command
│ ├── solve.go # Solve problem command
│ ├── status.go # Status dashboard command
│ └── ...
├── internal/
│ ├── database/ # GORM models and migrations
│ ├── problem/ # Problem service layer
│ ├── progress/ # Progress tracking service
│ ├── output/ # Output formatters (JSON, CSV, Table)
│ └── generator/ # Code and test generators
├── data/
│ └── problems/ # Problem library (JSON)
└── main.go # Application entry point
- Language: Go 1.21+
- CLI Framework: Cobra
- Config Management: Viper
- Database: SQLite with GORM
- Testing: Go's built-in
testingpackage + integration tests - Output: Custom ASCII table rendering,
encoding/json,encoding/csv
We welcome contributions! Whether it's:
- 🐛 Bug fixes
- ✨ New features
- 📝 Documentation improvements
- 🎨 UI/UX enhancements
- 📚 Adding new problems to the library
Please see CONTRIBUTING.md for guidelines.
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Make your changes
- Run tests (
go test ./...) - Commit with descriptive messages
- Push to your fork
- Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Inspired by the retro computing aesthetic of the 1980s
- Problem set curated from classic DSA interview questions
- Built with love for terminal enthusiasts and keyboard warriors
- 🐛 Bug Reports: GitHub Issues
- 💡 Feature Requests: GitHub Discussions
- 📧 Contact: Open an issue or discussion
Made with 💜 and ☕ by ak95asb
Train hard. Code harder. Level up your DSA skills in the dojo.
█▀▀ █▀█ █▀▄ █▀▀ █ █▄░█ ▀█▀ █░█ █▀▀ █▀▄ █▀█ ░░█ █▀█
█▄▄ █▄█ █▄▀ ██▄ █ █░▀█ ░█░ █▀█ ██▄ █▄▀ █▄█ █▄█ █▄█