在C语言中编写一个程序,打印出以Z形状排列的平方矩阵
/* Program to print a square matrix in Z form */ #include int main(){ int rows, cols, r, c, matrix[10][10]; clrscr(); /*Clears the Screen*/ printf("Please enter the number of rows for the Square matrix: "); scanf("%d", &rows); printf("