On Wednesday 08 January 2003 4:00 pm, Jean-Marc Lasgouttes wrote: > Lars, since the "(3)" is your doing, feel free to replace that with any > C++ally correct construct that may make you feel good. > > JMarc
Why not either of: #include <vector> #include <string> using std::vector; using std::string; void foo() { char const * const cstr[] = { "lyx", "text", "textparagraph" }; size_t const csize = sizeof(cstr) / sizeof(char*); vector<string> const v(cstr, cstr + csize); } void bar() { vector<string> v(3); v[0] = "lyx"; v[1] = "text"; v[2] = "textparagraph"; } -- Angus