Solution: Coloring Cells by Shortest Distance
Understand the solution to the “Coloring Cells by Shortest Distance” challenge.
We'll cover the following...
We'll cover the following...
Solution
Let's run the code given below to compare your output image.
Code explanation
Line 41: The method takes an optional parameter, from—representing the starting cell for which we want to calculate the distance—which defaults to an array containing the current object self ...