All that is true, but I went through some interviews last year at Google, and honestly, you really can&#x27;t afford to be thinking about things like this.  Nobody is going to ask you to just implement DFS, but you may get a problem that essentially reduces to DFS, if you can see it.  In my experience, you really will be expected to solve this problem at a whiteboard in 45 minutes.  Syntax and so forth won&#x27;t be an issue, but you can&#x27;t do too much handwaving, you really are expected to write code that solves the problem.<p>If you have to stop and reason your way back through DFS, I&#x27;d say there&#x27;s no way you&#x27;ll get this done in 45 minutes.  You need to know this stuff <i>cold</i>.<p>Rote memorization is useless, of course, because you won&#x27;t be able to adapt or modify these algorithms.  But there&#x27;s a kind of memorization in the level of sharpness and mental prep you need to have when you walk into those interviews.