sort vector of strings
#include <iostream>
#include <vector>
#include <algorithm>
int main() {
std::vector<std::string> myVector = {"banana", "apple", "orange", "grape"};
// Step 1: Use std::sort to sort the vector of strings
std::sort(myVector.begin(), myVector.end());
// Step 2: Display the sorted vector
std::cout << "Sorted Vector:" << std::endl;
for (const auto& element : myVector) {
std::cout << element << " ";
}
return 0;
}