C examples for Statement:while
Print int value under 10 using while loop
#include <stdio.h> int main()/*from www . j a v a2 s.c o m*/ { int x = 0; while ( x < 10 ) { printf("The value of x is %d\n", x); x++; } }