C++ Bil Ganjil antara bil s/d 10

#include <iostream>
#include <string>

using namespace std;
int main()
{
int i;

i =1;
cout<<“Menampilkan Bilangan Ganjil antara bilangan 0 s/d 10″<<endl;
while (i<10)
{
if (i%2==1)
cout << i << endl; i =i+2;
}
system(“pause”);
return 0;
}

Tinggalkan Balasan

Please log in using one of these methods to post your comment:

Logo WordPress.com

You are commenting using your WordPress.com account. Logout / Ubah )

Gambar Twitter

You are commenting using your Twitter account. Logout / Ubah )

Foto Facebook

You are commenting using your Facebook account. Logout / Ubah )

Foto Google+

You are commenting using your Google+ account. Logout / Ubah )

Connecting to %s