Run ID:109198
提交时间:2025-02-06 14:10:00
#include <iostream> using namespace std; int main(){ int n; cin>>n; for( int j=1;j<=n;j++) { for(int t=1;t<=j-1;t++) cout<<" "; for(int t=1;t<=-2*j+1+2*n;t++) cout<<"*"; cout<<endl; } for( int j=1;j<n;j++) { for(int t=1;t<=-j+n-1;t++) cout<<" "; for(int t=1;t<=2*j+2 -1;t++) cout<<"*"; // y = ax + b (1,5) - (2,3) // // cout<<endl; } return 0; }