Refactored the scatter function in the hybrid BFS stepwise algorithm.