#include <iostream>
using namespace std;
int main() {
const int size = 9;
const int half_size = size / 2;
for (int i = 0; i < half_size; i++)
{
for (int j = 0; j < i; j++)
std::cout << " ";
std::cout << "*";
for (int j = 0; j < (half_size - i) * 2; j++)
std::cout << " ";
std::cout << "*\n";
}
for (int i = 0; i < half_size; i++)
std::cout << " ";
std::cout << "*\n";
for (int i = half_size - 1; i >= 0 ; i--)
{
for (int j = 0; j < i; j++)
std::cout << " ";
std::cout << "*";
for (int j = 0; j < (half_size - i) * 2; j++)
std::cout << " ";
std::cout << "*\n";
}
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgp1c2luZyBuYW1lc3BhY2Ugc3RkOwoKaW50IG1haW4oKSB7Cgljb25zdCBpbnQgc2l6ZSA9IDk7CgkKCWNvbnN0IGludCBoYWxmX3NpemUgPSBzaXplIC8gMjsKCQoJZm9yIChpbnQgaSA9IDA7IGkgPCBoYWxmX3NpemU7IGkrKykKCXsKCQlmb3IgKGludCBqID0gMDsgaiA8IGk7IGorKykKCQkJc3RkOjpjb3V0IDw8ICIgIjsKCQlzdGQ6OmNvdXQgPDwgIioiOwoJCWZvciAoaW50IGogPSAwOyBqIDwgKGhhbGZfc2l6ZSAtIGkpICogMjsgaisrKQoJCQlzdGQ6OmNvdXQgPDwgIiAiOwoJCXN0ZDo6Y291dCA8PCAiKlxuIjsKCX0KCQoJZm9yIChpbnQgaSA9IDA7IGkgPCBoYWxmX3NpemU7IGkrKykKCQlzdGQ6OmNvdXQgPDwgIiAiOwoJc3RkOjpjb3V0IDw8ICIqXG4iOwoJCglmb3IgKGludCBpID0gaGFsZl9zaXplIC0gMTsgaSA+PSAwIDsgaS0tKQoJewoJCWZvciAoaW50IGogPSAwOyBqIDwgaTsgaisrKQoJCQlzdGQ6OmNvdXQgPDwgIiAiOwoJCXN0ZDo6Y291dCA8PCAiKiI7CgkJZm9yIChpbnQgaiA9IDA7IGogPCAoaGFsZl9zaXplIC0gaSkgKiAyOyBqKyspCgkJCXN0ZDo6Y291dCA8PCAiICI7CgkJc3RkOjpjb3V0IDw8ICIqXG4iOwoJfQoJCglyZXR1cm4gMDsKfQ==