title: sorting the variable data in specific order in tcl
body: <p>I have a list of elements in a varibale x as below,</p>
  <pre><code>set x {NAB BRX_v NABLE_e M0_I2C GPIO INTERRUT STRAP0}
  </code></pre>
  <p>I want to arrange them in specific order and assign to other variable and use this list for further processing.</p>
  <pre><code>set y {STRAP0 M0_I2C BRX_v NAB GPIO NABLE_e INTERRUT}
  </code></pre>
  <p>I want it to do in TCL, but I am not getting any idea how can I do.
  I can have a file which has the data in order. then I can compare the file data one by one with the variable <code>x</code>, if it is present will assign it to <code>y array[0]</code>. But how to do that.</p>