can please someone teach me how to create this program using
while statement.. this is the output should look like

0
2
4
6
8
10

-thanks.. :) need it asap...

Answer Posted / rameshwari

#include<stdio.h>
#include<conio.h>
void main()
{
int i=0;
while(i<=9)
{
printf("%d", i);
i=i+2;
}
getch();
}

Is This Answer Correct ?    4 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why is c still so popular?

607


Explain how can a program be made to print the name of a source file where an error occurs?

677


What is a function simple definition?

604


Write a program to check whether a number is prime or not using c?

567


Can you define which header file to include at compile time?

576






how can i access hard disk address(physical address)? are we access hard disk by using far,near or huge pointer? if yes then please explain.....

1364


What is this pointer in c plus plus?

586


Explain the advantages and disadvantages of macros.

612


Can we access array using pointer in c language?

638


Write a program to reverse a linked list in c.

635


write a program for the normal snake games find in most of the mobiles.

1779


What is boolean in c?

601


in any language the sound structure of that language depends on its a) character set, input/output function, its control structures b) character set, library functions, input/output functions its control structures c) character set, library functions, control sturctures d) character set, operators, its control structures

670


Explain how do you search data in a data file using random access method?

687


You are to write your own versions of strcpy() and strlen (). Call them mystrcpy() and mystrlen(). Write them first as code within main(), not as functions, then, convert them to functions. You will pass two arrays to the function in the case of mystrcpy(), the source and target array.

1770