Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<stdio.h>
- #include<stdlib.h>
- #define colmax 10
- #define rowmax 12
- int main()
- {
- int i,j,sum=1;//initializing variables
- for(i=1;i<=rowmax;i++)//this iterates rows from 1 to 12
- {
- for(j=1;j<=colmax;j++)//this iterates colums from 1 to 10 everytime
- {
- sum=i*j;//and this multiplies all iterated elements to row number
- printf("|%4d",sum);//printing the iterated and multiplied elements
- }
- printf("\n");
- printf("------------------------------------------------------|");
- printf("\n");
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement