Mission 15: "The Universal Translator & Network Consolidation" 🌐
Your first task is to populate the command Trie. The first command to add is 'shutdown'.
00:00
Mission Objective
Implement the logic to insert the word 'shutdown' into the Trie. Iterate through each character, creating new nodes as necessary, and mark the final node as the end of a word.
Step 1 / 2
1. The Story: The Mission Briefing
"The Labyrinth's communication network is fragmented. You must first use a Trie to build an efficient translation index for all system commands. Then, use a Disjoint Set Union (DSU) to identify and merge all fragmented network circuits into a single, cohesive unit."
2. The Problem
Using a Trie for prefix searching and a DSU for checking and merging connected components.
3. The Task
You will first insert a series of commands into a Trie. Then, you will process a list of network connections using a DSU to determine the final number of distinct network circuits.
4. Concepts Applied
Practical application of Trie and DSU data structures.