#include<iostream> #include<algorithm> #include<cstring> #include<queue> using namespace std; int main() { int n; cin >> n; for (int i = 0; i < n; i++) { int m; cin >> m; for (int i = 1; i <= m-1; i++) { for (int j = m - 1; j >= i; j--) cout << " "; for (int j = 1; j <= 2 * i - 1; j++) cout << "*"; cout << endl; } for (int i = 1; i <= 2 * m - 1; i++) cout << "*"; cout << endl; for (int i = m-1; i >= 1; i--) { for (int j = i; j <= m - 1; j++) cout << " "; for (int j = 1; j <= 2 * i - 1; j++) cout << "*"; cout << endl; } cout << endl; } return 0; }
0.0分
0 人评分