title: Generating a string based on vector data
body: <p>Let's say that i have an unknown size  array like 0,1,2,3...</p>
  
  <pre><code>for(int i = 0; i &lt; array.size(); i++)
  {
    string name;
    int number;
  
    if (array[i] == 0)
    {
      name ="jack";
      number="10";
    }
    else if (array[i] == 1)
    {
      name="alice";
      number=15"; 
    }
    //....
  }
  </code></pre>
  
  <p>Using this data I would like to generate a string like:</p>
  
  <pre><code>string text = name(number)+name(number)+name(number)...
  </code></pre>
  
  <p>There must be  array.size() times name(number) in string</p>
  
  <p>How do I do write code for this?</p>