int main(){ std::cout << "enter the vector, for exit enter the '.'" << std::endl; // any symbol in '' do{ alph.push_back(getchar()); } while (alph[alph.size() - 1] != '.'); // any alph.pop_back(); // delete end symbol std::sort(alph.begin(), alph.end()); for (int i = 0; i < alph.size(); i ++){ std::cout << alph[i] << " "; } system("pause"); }