Skip to content

Instantly share code, notes, and snippets.

View Jjateen's full-sized avatar
😸

Jjateen Gundesha Jjateen

😸
View GitHub Profile
@Jjateen
Jjateen / tower_of_hanoi.sh
Created May 1, 2026 04:58
Tower of hanoi (simple graphics) using bash, one can run directly or randomize to have some fun
#!/usr/bin/env bash
# hanoi solver - 3 pegs, solve to C
#
# usage: bash tower_of_hanoi.sh [num_disks] [--random]
# num_disks number of disks to use (default: 4)
# --random scatter disks across A and B instead of stacking all on A
N=4
RANDOM_START=0
for arg in "$@"; do