"HasExit" algorithm changed.

"HasExit" algorithm changed "AddNeghibour" method removed.