#include <iostream>
#include <sstream>
#include <vector>
#include <set>
#include <tuple>
int main()
{
std::string line;
while(getline(std::cin, line))
{
std::stringstream ss(line);
std::multiset<int> mset;
int n;
while(ss >> n)
mset.insert(n);
std::set<std::tuple<int, int, int>> triplets;
const std::vector<int> numbers(mset.begin(), mset.end());
for(size_t i = 0; i < numbers.size() - 3; i++)
{
size_t start = i + 1, end = numbers.size() - 1;
while(start < end)
{
int sum = numbers[i] + numbers[start] + numbers[end];
if(sum == 0)
{
triplets.insert(std::make_tuple(numbers[i], numbers[start], numbers[end]));
end--;
continue;
}
sum > 0 ? end-- : start++;
}
}
for(const auto& t: triplets)
{
std::cout << std::get<0>(t) << ' ';
std::cout << std::get<1>(t) << ' ';
std::cout << std::get<2>(t) << std::endl;
}
std::cout << std::endl;
}
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgoJI2luY2x1ZGUgPHNzdHJlYW0+CgkjaW5jbHVkZSA8dmVjdG9yPgoJI2luY2x1ZGUgPHNldD4KCSNpbmNsdWRlIDx0dXBsZT4KCQoJaW50IG1haW4oKQoJewoJCXN0ZDo6c3RyaW5nIGxpbmU7CgkJd2hpbGUoZ2V0bGluZShzdGQ6OmNpbiwgbGluZSkpCgkJewoJCQlzdGQ6OnN0cmluZ3N0cmVhbSBzcyhsaW5lKTsKCQkJc3RkOjptdWx0aXNldDxpbnQ+IG1zZXQ7CgkJCWludCBuOwoJCQl3aGlsZShzcyA+PiBuKQoJCQkJbXNldC5pbnNlcnQobik7CgkKCQkJc3RkOjpzZXQ8c3RkOjp0dXBsZTxpbnQsIGludCwgaW50Pj4gdHJpcGxldHM7CgkJCWNvbnN0IHN0ZDo6dmVjdG9yPGludD4gbnVtYmVycyhtc2V0LmJlZ2luKCksIG1zZXQuZW5kKCkpOwoJCQlmb3Ioc2l6ZV90IGkgPSAwOyBpIDwgbnVtYmVycy5zaXplKCkgLSAzOyBpKyspCgkJCXsKCQkJCXNpemVfdCBzdGFydCA9IGkgKyAxLCBlbmQ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