fork download
  1.  
  2. #include <iostream>
  3. #include <map>
  4. using namespace std;
  5. int main(){
  6. map<int,string> v{{0,"Heathrow"},{2,"Edinburgh"},{4,"London"},{6,"Liverpool"},{8,"Oxford"}};
  7. string t(255,' ');for(auto&m:v){int i=m.first;t[i++]='*';for(auto&c:m.second)t[i++]=c;}cout<<t;
  8. }
Success #stdin #stdout 0s 3464KB
stdin
Standard input is empty
stdout
*H*E*L*L*Oxfordl