#include
#include <Windows.h>
using namespace std;
int main(void) {
int rows;
int cols;
cout << "请输入行数: ";
cin >> rows;
cout << "请输入每行需要打印的列数: ";
cin >> cols;
for (int i=0; i<rows; i++) {
for (int j=0; j<cols; j++){
cout << "*";
}
cout << endl;
}
system("pause");
return 0;
}