title: taking array and building stream expressions in tcl
body: <p>I am trying to build a STREAM expression from the following array. the issue is, I want to copy particular strings from the array value and place repeat them at another place in the entire string. here is my code, and the desired outcome.</p>
  
  <p>desired outcome:  STREAM::expression @$val-1@$val-2$val-1@@$val-3@$val-4$val-3@
  original string:  $val-2$val-1$val-4$val-3
  basically, val-1 represents a short string that i want to replace with a second string appended to it. another way to do an insertion in other words.</p>
  
  <pre><code>array set {
    key1 $val-2$val-1$val-4$val-3
  }
  </code></pre>
  
  <p>i have code that puts the @ symbols, i just need to move the strings around.</p>