#include <stdio.h>
#include <string.h>
int main()
{
int i, h = 3;
char buf[80];
for (i = 0; i < h; i++) {
printf("%*.*s\n", h
+ i
, i
* 2 + 1, buf
); }
for (i = h - 2; 0 <= i; i--) {
printf("%*.*s\n", h
+ i
, i
* 2 + 1, buf
); }
return 0;
}
I2luY2x1ZGUgPHN0ZGlvLmg+CiNpbmNsdWRlIDxzdHJpbmcuaD4KCmludCBtYWluKCkKewoJaW50IGksIGggPSAzOwoJY2hhciBidWZbODBdOwoKCW1lbXNldChidWYsICcqJywgaCAqIDIgLSAxKTsKCWZvciAoaSA9IDA7IGkgPCBoOyBpKyspIHsKCQlwcmludGYoIiUqLipzXG4iLCBoICsgaSwgaSAqIDIgKyAxLCBidWYpOwoJfQoJZm9yIChpID0gaCAtIDI7IDAgPD0gaTsgaS0tKSB7CgkJcHJpbnRmKCIlKi4qc1xuIiwgaCArIGksIGkgKiAyICsgMSwgYnVmKTsKCX0KCXJldHVybiAwOwp9Cg==