Selasa, 04 Oktober 2011

Perulangan Pada C++ ( Part 2)

Contoh program sederhana C++

// tugas modul3.cpp : Defines the entry point for the console application.
//

#include "stdafx.h"
#include "iostream.h"
#include "conio.h"
void main()
{
      int a;
      for (a=1; a<15; a++)
      {
            if (a==3) continue;
            cout <<" angka "<< a <<endl;
            if (a==11) break;
      }
      getch();

0 komentar:

Posting Komentar

 
Design by Free WordPress Themes | Bloggerized by Lasantha - Premium Blogger Themes | Laundry Detergent Coupons