Problem
The current Radix Sort implementation has several issues affecting performance and user experience:
Unnecessary array copying during visualization: Creating full array copies on every iteration
Incorrect comparison counting: Counting array accesses as comparisons (not meaningful for Radix Sort)
Inefficient color updates: Creating new color arrays repeatedly
Memory overhead: Multiple intermediate arrays created unnecessarily
Poor visualization: Updates happen during placement phase, making it hard to follow
Current Behavior
Comparisons counter inflates artificially (array indexing isn't comparison)
Excessive re-renders due to multiple state updates per element
Visualization shows incomplete intermediate states
Expected Behavior
Show clear digit-by-digit processing
Highlight current digit being sorted
Display counting buckets visually
Accurate statistics (array accesses, not comparisons)
Smooth, understandable visualization
Problem
The current Radix Sort implementation has several issues affecting performance and user experience:
Unnecessary array copying during visualization: Creating full array copies on every iteration
Incorrect comparison counting: Counting array accesses as comparisons (not meaningful for Radix Sort)
Inefficient color updates: Creating new color arrays repeatedly
Memory overhead: Multiple intermediate arrays created unnecessarily
Poor visualization: Updates happen during placement phase, making it hard to follow
Current Behavior
Comparisons counter inflates artificially (array indexing isn't comparison)
Excessive re-renders due to multiple state updates per element
Visualization shows incomplete intermediate states
Expected Behavior
Show clear digit-by-digit processing
Highlight current digit being sorted
Display counting buckets visually
Accurate statistics (array accesses, not comparisons)
Smooth, understandable visualization