Company: Ibm_31oct
Difficulty: medium
Lost Fragments Problem Description A message-sending service has broken down, causing fragments of messages to be lost. A message is a string containing space-separated words. Given the sent message and the received message, find the words that are present in the sent message but not in the received message. Return these words in the order they appear in the sent message. Note that all words in the received message occur in the same order in the sent message, but they do not have to be contiguous. Complete the function lostFragments in the editor with the following parameters: vector lostFragments(string sent, string received) string sent : the message sent through the service string received : the message received Returns: string[] : an array of strings that contains all words in sent that are not present in received, in the order they occur in sent. Examples Example 1: Input: sent = "I am a programmer", received = "I programmer" Output: ["am", "a"] Explanation: The words "am" and "a"