xplshn
·
2025-08-13
loop.b
B
1main() {
2 extrn printf;
3 auto i;
4
5 // Ascending: 0 to 15
6 i = 0;
7 while (i <= 15) {
8 printf("%d\n", i);
9 i++;
10 }
11
12 // Separator
13 printf("----\n");
14
15 // Descending: 15 to 0
16 i = 15;
17 while (i >= 0) {
18 printf("%d\n", i);
19 i--;
20 }
21}