Program C++ “Menentukan Nama Korea Dari tanggal lahir”

annyeong ^^
kali ini gue mau share ttg tugas pelajaran gue. kami disuruh bikin program dari c++, bebas dan yang penting menarik dan gak simpel --"
awalnya gue mau bikin kamus korea, tapi minimum kata"a harus 200 (==") lgpula byk errornya dan gue bingung. Jadi gue memutuskan untuk bikin 
ini. Lebih simpel, enak dan semoga aja berhasil (amiiiin).

Oke, ini nih rumus c++ program Menentukan Nama Korea dari Tanggal Lahir 

#include<iostream.h>
#include <stdio.h>
void main ()
{

    int tahun;
	int bulan;
	int tanggal;
cout<<"===================================================="<<endl;
;cout<< "Menentukan Nama Korea Berdasarkan Tanggal Lahir"<<endl;
cout<<"===================================================="<<endl;

 printf("MASUKKAN ANGKA TERAKHIR TAHUN ANDA (0-9) : ");
        scanf("%d",&tahun);
        switch (tahun)
        {
        case 0:printf("Park\n");
            break;
		case 1:printf("Kim\n");
            break;
        case 2:printf("Shin\n");
            break;
        case 3:printf("Choi\n");
            break;
        case 4:printf("Song\n");
            break;
        case 5:printf("Kang\n");
            break;
        case 6:printf("Han\n");
            break;
        case 7:printf("Lee\n");
            break;
        case 8:printf("Sung\n");
            break;
        case 9:printf("Jung\n");
            break;
       default:printf("Salah!\n");
        }
        printf("MASUKKAN BULAN LAHIR ANDA (1-12) : ");
        scanf("%d",&bulan);
        switch (bulan)
        {
        case 1:printf("Young\n");
            break;
        case 2:printf("Ji\n");
            break;
        case 3:printf("Ji\n");
            break;
        case 4:printf("Hye\n");
            break;
        case 5:printf("Dong\n");
            break;
        case 6:printf("Sang\n");
            break;
        case 7:printf("Ha\n");
            break;
        case 8:printf("Hyo\n");
            break;
        case 9:printf("Soo\n");
            break;
        case 10:printf("Eun\n");
            break;
        case 11:printf("Hyun\n");
            break;
        case 12:printf("Rae\n");
            break;
        default:printf("Salah!\n");
        }
		printf("MASUKKAN TANGGAL LAHIR ANDA (1-31) : ");
		scanf("%d",&tanggal);
		switch (tanggal)
		{
		case 1:printf("Hwa\n");
            break;
        case 2:printf("Woo\n");
            break;
        case 3:printf("Joon\n");
            break;
        case 4:printf("Hee\n");
            break;
        case 5:printf("Kyo\n");
            break;
        case 6:printf("Kyung\n");
            break;
        case 7:printf("Wook\n");
            break;
        case 8:printf("Jin\n");
            break;
        case 9:printf("Jae\n");
            break;
        case 10:printf("Hoon\n");
            break;
        case 11:printf("Ra\n");
            break;
        case 12:printf("Bin\n");
			break;
		case 13:printf("Sun\n");
            break;
        case 14:printf("Ri\n");
            break;
        case 15:printf("Soo\n");
            break;
        case 16:printf("Rim\n");
            break;
        case 17:printf("Ah\n");
            break;
        case 18:printf("Ae\n");
            break;
        case 19:printf("Neul\n");
            break;
        case 20:printf("Mun\n");
            break;
        case 21:printf("In\n");
            break;
        case 22:printf("Min\n");
            break;
        case 23:printf("Ki\n");
            break;
        case 24:printf("Sang\n");
            break;
		case 25:printf("Byung\n");
            break;
        case 26:printf("Seok\n");
            break;
        case 27:printf("Gun\n");
            break;
        case 28:printf("Yoo\n");
            break;
        case 29:printf("Sub\n");
            break;
        case 30:printf("Won\n");
            break;
        case 31:printf("Sup\n");
            break;
        default:printf("Salah!\n");

        }
}

Nah ini hasil akhirnya :p

2 Comments

Filed under Korean, Pelajaran

2 responses to “Program C++ “Menentukan Nama Korea Dari tanggal lahir”

  1. cara make ntu program gimana? ga ada tutorial

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s