#include<stdio.h> #include<conio.h> void main() { int i,j; clrscr(); for(i=1;i<=5;i++) { for(j=1;j<=5;j++) if(i==1||i==5|| j==1||j==5) printf("%3d",1); else if(i==2|| i==4||j==2||j==4) printf("%3d",2); else printf("%3d",3); printf("\n"); } getch(); } |
___________________________________________________________________________
Post a Comment