Debugging recursive algorithms - C#