#include <iostream>
#include <string>
using namespace std;
string b1, b2, a1, a2;
int main()
{
int t, h;
char c;
scanf("%d", &t);
while (t--)
{
getchar();
scanf("%c %d", &c, &h);
int i = h/6 + 1;
a1 = "";
a2 = "";
a1.insert(0,i,' ');
a2.insert(0,i,c);
a2 = a2 + a2;
h -= 3;
int j = h/2;
a1.insert(i,h-j,c);
a2.insert(i,h-j,' ');
cout<<a1<<endl;
for (i=0;i<j;++i) cout<<a2<<endl;
cout<<a1<<endl;
for (i=0;i<h-j;++i) cout<<a2<<endl;
cout<<a1<<endl;
if (t!=0) cout<<endl;
}
return 0;
}
hdu 1256
最新推荐文章于 2019-06-29 14:23:46 发布