Adjacency Lists --------------- You will have to read in a labelled, directed graph and then output the list of edges out of selected nodes. Input ----- The input will contain multiple instances. The first line of each instance will contain two integers n and m, representing the number of nodes and edges in the graph, respectively. These values will satisfy 1 <= n <= 100000 and 0 <= m <= 100000. Following this, there will be m lines, each containing two integers i and j and a label x, where 1 <= i <= n and 1 <= j <= n, indicating that there is an edge from node i to node j with label x. The label will contain alpha-numeric characters and no spaces. Following this, there will be a sequence of lines that each contain an integer i, where 0 <= i <= n. The end of this sequence will be indicated by the value i=0. The end of the input will be indicated by a line with m=n=0. Output ------ For each input instance, you should do the following. For each integer i>0 that appears on a line by itself, you should print a list of nodes that can be reached from node i by following a single edge, and the label on that edge. Use the format indicated in the sample output below. Remember to print a blank line in between the outputs for different problem instances (but do not print a blank line at the end of the output). Sample Input ------------ 5 6 1 3 AB1 2 5 X007 3 1 R2D2 2 3 C3P0 4 2 EEZ 3 4 3TY 5 3 1 0 3 3 1 2 YYZ 2 3 UZ7 1 3 123 3 2 1 0 0 0 Sample Output ------------- Edges out of node 5: Edges out of node 3: 1 R2D2 4 3TY Edges out of node 1: 3 AB1 Edges out of node 3: Edges out of node 2: 3 UZ7 Edges out of node 1: 2 YYZ 3 123