René's URL Explorer Experiment


Title: #332 - Reconstruct Itinerary - LeetCode JavaScript Solutions

Open Graph Title: #332 - Reconstruct Itinerary - LeetCode JavaScript Solutions

X Title: #332 - Reconstruct Itinerary - LeetCode JavaScript Solutions

Description: You are given a list of airline tickets where tickets[i] = [fromi, toi] represent the departure and the arrival airports of one flight. Reco...

Open Graph Description: You are given a list of airline tickets where tickets[i] = [fromi, toi] represent the departure and the arrival airports of one flight. Reco...

X Description: You are given a list of airline tickets where tickets[i] = [fromi, toi] represent the departure and the arrival airports of one flight. Reco...

Keywords:

Opengraph URL: https://leetcodejavascript.com/solutions/reconstruct-itinerary

direct link

Domain: leetcodejavascript.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"Code","url":"https://leetcodejavascript.com/solutions/reconstruct-itinerary","name":"#332 - Reconstruct Itinerary - LeetCode JavaScript Solutions","description":"You are given a list of airline tickets where tickets[i] = [fromi, toi] represent the departure and the arrival airports of one flight. Reco...","programmingLanguage":"JavaScript","codeRepository":"https://github.com/JoshCrozier/leetcode-javascript","codeSampleType":"JavaScript","text":"/**\n * @param {string[][]} tickets\n * @return {string[]}\n */\nvar findItinerary = function(tickets) {\n const graph = new Map();\n const itinerary = [];\n\n for (const [from, to] of tickets) {\n if (!graph.has(from)) {\n graph.set(from, []);\n }\n graph.get(from).push(to);\n }\n\n for (const [_, destinations] of graph) {\n destinations.sort().reverse();\n }\n\n dfs('JFK');\n\n return itinerary.reverse();\n\n function dfs(airport) {\n while (graph.has(airport) && graph.get(airport).length) {\n dfs(graph.get(airport).pop());\n }\n itinerary.push(airport);\n }\n};","keywords":"LeetCode 332, #332 - Reconstruct Itinerary, Hard, JavaScript solution","learningResourceType":"Code","isAccessibleForFree":true,"educationalLevel":"intermediate","interactivityType":"mixed"}

authorLeetCodeJavascript.com
og:typearticle
og:imagehttps://leetcodejavascript.com/og-image.jpg
og:site_nameLeetCode JavaScript Solutions
twitter:cardsummary_large_image
twitter:urlhttps://leetcodejavascript.com/solutions/reconstruct-itinerary
twitter:imagehttps://leetcodejavascript.com/og-image.jpg
twitter:creator@joshcrozier
theme-color#1f2937

Links:

LeetCodeJavascript.com https://leetcodejavascript.com/
Star on GitHubhttps://github.com/JoshCrozier/leetcode-javascript
Back to all solutionshttps://leetcodejavascript.com
View on LeetCode https://leetcode.com/problems/reconstruct-itinerary/
View on GitHubhttps://github.com/JoshCrozier/leetcode-javascript/blob/master/solutions/0332-reconstruct-itinerary.js
Depth-First Search https://leetcodejavascript.com/tags/depth-first-search
Graph https://leetcodejavascript.com/tags/graph
Eulerian Circuithttps://leetcodejavascript.com/tags/eulerian-circuit
Josh Crozierhttps://joshcrozier.com

Viewport: width=device-width,initial-scale=1

Robots: index, follow


URLs of crawlers that visited me.