// program while do.
// program while menggunakan counter
#include<iostream.h>
main()
{
int a;
a=1;
while(a<=10)
{
cout<< a;
a++;
}
}
// program while tidak menggunakan counter
#include<iostream.h>
main()
{
int a;
while(a != 1 )
{
cout << " masukan nilai A : ";
cin >> a;
}
}