C Language "Simple While Loop" program with output

 #include <stdio.h>

int main() { int i = 1; // Initialize the counter to 1 while (i <= 5) { // Check if the counter is less than or equal to 5 printf("%d\n", i); // Print the current value of i i++; // Increment the counter by 1 } return 0; }


Output:
1 2 3 4 5

Comments

Popular posts from this blog

Video Formats

Where video editing is used

File saving and folder management