BFS method implementation
Merge branch 'master' of https://github.com/SCOREC/core