The specific code is as follows:
#include <stdio.h> int main(){ int i,j,n; for(i=1;i<=9;i++){ // 将下面的for循环注释掉,就输出左下三角形 for(n=1; n<=9-i; n++) printf(" "); for(j=1;j<=i;j++) printf("%d*%d=%2d ",i,j,i*j); printf("\n"); } return 0; }
The running results are as follows:
The operation after removing the loop The results are as follows:
# Recommended tutorial: c language tutorial
The above is the detailed content of c language to print multiplication table. For more information, please follow other related articles on the PHP Chinese website!