C
This commit is contained in:
20
DeitelC/Chapter3/FloydsTriangle.c
Normal file
20
DeitelC/Chapter3/FloydsTriangle.c
Normal file
@ -0,0 +1,20 @@
|
||||
#include <stdio.h>
|
||||
|
||||
int main(void) {
|
||||
|
||||
int a = 1;
|
||||
int b = 1;
|
||||
int i = 1;
|
||||
|
||||
while(a < 11) {
|
||||
while(b <= a) {
|
||||
printf("%d\t",i);
|
||||
i++;
|
||||
b++;
|
||||
}
|
||||
printf("\n");
|
||||
b = 1;
|
||||
a++;
|
||||
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user