Frage im Vorstellungsgespräch bei TikTok

Find the shortest average path node. Also needed time complexity