If a device present in one network wants to communicate with the device present in another network, then logical address is required to or more networks are connected by routers or switches. Router network player selects the best possible path for source to destination, further it uses routing algorithm.