Changed path length definition to include both source and destination.
Simplified implementConnection implementation.
Improved ToString.
Refactoring toString.
Improved grid printing.