Tuesday , December 6 2016
Home / C / While Loop in C Syntax, Flow Chart and Example

While Loop in C Syntax, Flow Chart and Example

While Loop in C: While loop is a conditional control looping statement in C which is used in iterative logics. In While Loops the et of instructions given inside the loop keeps on repeating until the condition becomes false.

While Loop Syntax

Here, statement(s) may be a single statement or a set of multiple statements.

Condition can be any expression which evaluated as an integer value and is False if results in ZERO (0) or True if results in any NON ZERO (!= 0) . The loop iterates if condition is true and terminates if condition is false.

Flow Chart of a While Loop

While loop syntax and programming tutorial

Example

Output:

1  3  5  7  9  11  13  15  17  19

Also See: Sum Of Two Numbers Using While Loop

 

Also See:   C program for Sum of two number using While LOOP

Check Also

Hide Mouse Pointer C Program

How to Hide a Mouse Pointer Program in C : This program will show and hide ...

Leave a Reply

Your email address will not be published. Required fields are marked *

Preventing spam * Time limit is exhausted. Please reload the CAPTCHA.