free c programming course
Tuesday, 8 September 2009
DRAW THE FOLLOWING PYRAMID IN C
1
0 1
1 0 1
0 1 0 1
void main(){ int i,j; clrscr(); for(i=1;i<10;i++) { for(j=i;j>=1;j--) { printf("%d",j%2); } printf("\n"); } getch();}
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment