Wednesday, May 11, 2016

HackerRank – Connected Cell in a Grid - Warm up with Five Practices (IV)

May 11, 2016


Warm up an algorithm like tennis sports, work on different strokes before she plays matches. Julia chose the algorithm - Connected Cell In a Grid to warm up for a few hours. 

Last time, less than 1 month ago, Julia did work on this algorithm – connected cell in a grid. And then, she started to warm up again.

Here is one of blogs last practice on April 16, 2016:


Fourth practice, using DFS – recursive function, but use an argument – reference int to track value

Question and Answer:
1. What do you like the approach - DFS, recursive function, use an argument - reference to track the count? 

Julia likes to use an argument to track the count, and let the recursive function return void. 

No comments:

Post a Comment