push_swap
Enter numbers. Watch two stacks turn a constraint into a sorted result.
STACK A top ↓
STACK B top ↓
JavaScript minimum-first model using valid stack operations. The C repository uses a cost-based strategy; these move counts are separate.
See the C implementation and measured benchmark →