Google interview question

Implement typical graph algorithm in both recursive and iterative manner