githubNonFunziona/2-4-d.spp

19 lines
339 B
Plaintext
Raw Normal View History

2024-12-05 10:57:14 +00:00
#include <algorithm>
#include <iostream>
#include <string>
#include <vector>
int main() {
std::vector<std::string> a;
std::string b;
while (std::getline(std::cin, b)) {
a.push_back(b);
}
std::sort(a.rbegin(), a.rend());
for (size_t i = 0; i != a.size(); ++i) {
std::cout << a[i] << "\n";
}
}