 To rebuild the dictionary in the same way as it was built during encoding, it also obtains the next value from the input and adds to the dictionary the concatenation of the current string and the first character of the string obtained by decoding the next input value, or the first character of the string just output if the next value can not be decoded (If the next value is unknown to the decoder, then it must be the value added to the dictionary this iteration, and so its first character must be the same as the first character of the current string being sent to decoded output).The decoder then proceeds to the next input value (which was already read in as the "next value" in the previous pass) and repeats the process until there is no more input, at which point the final input value is decoded without any more additions to the dictionary.In this way, the decoder builds a dictionary that is identical to that used by the encoder, and uses it to decode subsequent input values.