Comment on Tutorial - while (1) Loops in C++ By Reema sen



Comment Added by : Jorgeus

Comment Added at : 2012-08-30 09:07:03

Comment on Tutorial : while (1) Loops in C++ By Reema sen
#include <iostream>
using namespace std;

//While loop

main()

{
int num=1;
while(num<=10)
{
cout<<num<<endl;
num++;
}
return 0;
}


Output:
1
2
3
4
5
6
7
8
9
10

Try this, it's very simple


View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. Hi.
How we can create list with menuitem in

View Tutorial          By: omid at 2008-09-08 02:09:50

2. Please guys i need sms.zip. I tried SMS.RAR but al
View Tutorial          By: Waseem at 2010-03-06 15:48:40

3. The above example for abstract class is very good.
View Tutorial          By: saafia at 2013-08-19 14:33:54

4. Suppose we are executing a try block and faced an
View Tutorial          By: Suindu De at 2015-10-08 10:56:56

5. This article is very good. It is very easy to unde
View Tutorial          By: Vandana B.Dass at 2010-02-01 00:54:54

6. hey. How would i get the ClientLists displayed in
View Tutorial          By: andrew at 2009-07-24 14:10:24

7. ma'am aiza teaches us very well.. >< i like
View Tutorial          By: chai at 2011-02-07 07:06:36

8. Very nice demo. thanks! :)
View Tutorial          By: Nikhil Gala at 2012-01-13 10:03:57

9. tnx
View Tutorial          By: arion at 2011-06-03 01:24:30

10. Easy to understand........ thanks man
View Tutorial          By: vikash bhardwaj at 2013-06-25 07:07:54