title: Find move order words in set
body: <p>This is an example because i have n random set with n random words in each set. 
  EXAMPLE:
  I have 3 sets of strings</p>
  
  <pre><code>Set1 {"hello","yes"}
  
  Set2 {"dog","family"}
  
  Set3 {"sea","sun"}
  </code></pre>
  
  <p>If I read from input: <code>C hello dog</code> -
  I have to concatenate <code>Set1</code> and <code>Set2</code> <code>{C = Concatenate}</code></p>
  
  <p>If I read from input: <code>M dog sun</code> -
  I have to move only the word  <code>dog</code> in <code>Set3</code> (delete it from <code>Set2</code>) <code>{M = Move}</code></p>
  
  <p>I think i need of vector <code>&lt;list&lt;string &gt; &gt;</code> tail; I have to search the two word in what set are and execute the command.</p>
  
  <p>Also i need to optimize the memory, so maybe I should order each set, the search will be more faster.</p>
  
  <p>Some advice on an appropriate way to do it? Thanks all.</p>