Answers for "print 0 1 2 3 4 in c while loop"

C
1

print 0 1 2 3 4 in c

//prints 0 1 2 3 4 , i<..num.. of loop iterations.
for (i = 0; i < 5; ++i) 
{
  printf("%d", i);
}
Posted by: Guest on April-23-2021
0

print 0 1 2 3 4 in c while loop

int k=0;

while (k <= 5)
{
    printf("%d", k);
    k = k + 1;
}
Posted by: Guest on April-23-2021

Code answers related to "print 0 1 2 3 4 in c while loop"

Code answers related to "C"

Browse Popular Code Answers by Language