in computer network Berland State University n router number 1 n some pair router connect patch cord information transmit patch cord direction the network arrange way communication router directly router possible there cycle network path pair router patch cordsunfortunately exact topology network lose administrator in order restore follow auxiliary information collectedFor patch cord p directly connect router list router locate patch cord p relatively known in word router path router go p know So router ki list ki number patch cord connect iFor example let network consist router connect chain 123 then router 1 single patch cord connect router single list contain router 2 3 router 2 patch cord connect second router list list contain router 1 router 3 router 3 single patch cord connect router single list contain router 1 2 your task help administrator restore network topology e identify pair router directly connect patch cord