On Wednesday, May 29, 2013

Berikut ini contoh coding C++ Program Peminjaman DVD yang disusun oleh mahasiswa Jurusan Teknik Informatika STT-PLN tahun 2012.Check this out guys :)

#include<iostream.h>
#include<stdio.h>
#include<conio.h>
main()
{int hari,film;
long int i,total;
for (i=1;i<=200;i++)
{    clrscr();
cout<<"\t\t\t L O A D I N G \n\n\t\t\t\t/";
clrscr();
cout<<"\t\t\t L O A D I N G \n\n\t\t\t\t-";
clrscr();
cout<<"\t\t\t L O A D I N G \n\n\t\t\t\t|";
clrscr();
cout<<"\t\t\t L O A D I N G \n\n\t\t\t\t/";
clrscr();
cout<<"\t\t\t L O A D I N G \n\n\t\t\t\t-";
}
clrscr();
cout<<"\n\t\tDiko Suprayogi            (2012-31-046)"<<endl;
cout<<"\n\t\tShentin Abigail        (2012-31-054)"<<endl;
cout<<"\n\t\tEndah Tri Utari           (2012-31-065)"<<endl;
cout<<"\n\t\tHanan Tahriry Rava'ie     (2012-31-057)\n"<<endl;
cout<<"====KELOMPOK 3================================================================="<<endl;
cout<<"\t\t\t     *     * * *   **   "<<endl;
cout<<"\t\t\t    * *    *   *  * *   "<<endl;
cout<<"\t\t\t   *   *   * * *    *   "<<endl;
cout<<"\t\t\t  * * * *  *        *   "<<endl;
cout<<"\t\t\t *       * *      * * * "<<endl;
cout<<"====KELOMPOK 3================================================================="<<endl;
cout<<endl;
cout<<"\t\t\tClick Enter !";
getche();
char almt[30],nama[30],telp [20], pin[20], pil;

cout<<" \t\t||RENTAL DVD 'HORE-HORE'||\t\t\t\t \n";
cout<<" \t\t|| MOVIE IN YOUR EYES!\t||\t\t\t\t \n";
cout<<" \t\t|| OPEN 24 HOURS\t||\t\t\t\t \n";
cout<<"\tJl. Suka 005 Kelurahan Senang Kota Gembira\n";
cout<<"==================================================================\n\n";

cout<<"1. Nama Peminjam : "; gets(nama);
cout<<"2. Alamat : "; gets(almt);
cout<<"3. Telepon/HP : ";cin>>telp;
cout<<"4. Tanggal pinjam : ";gets(pin);cout<<endl;
cout<<"Pilih film Anda !\n\n";
cout<<"a. Action\n";
cout<<"b. Comedy\n";
cout<<"c. Drama\n";
cout<<"d. Documentary\n";
cout<<"e. Romance\n";
cout<<"f. Horror\n\n";
cout<<"Masukkan pilihan film Anda [a/b/c/d/e/f]: ";
cin>>pil;
if (pil=='a')
{
cout<<"\t\t66**********************99\n";
cout<<"\t\t||\tACTION MOVIE\t||\n";
cout<<"\t\t99**********************66\n\n";
cout<<"\t 1. The Chronicles of Riddick (2004)\n";
cout<<"\t 2. The Mummy: Tomb of the Dragon Emperor (2008)\n";
cout<<"\t 3. Underworld: Evolution (2006)\n";
cout<<"\t 4. Rise of the Lycans (2009)\n";
cout<<"\t 5. War (2007)\n";
cout<<"\t 6. Bandidas (2006)\n";
cout<<"\t 7. Domino (2005)\n";
cout<<"\t 8. Enough (2002)\n";
cout<<"\t 9. Cradle of Life (2003)\n";
cout<<"\t 10. V for Vendetta (2005)\n";
cout<<"\nPilihan Film yang Disewa : ";cin>>film;
switch(film)
{
case 1 :
cout<<"\n1. The Chronicles of Riddick (2004)\n";
cout<<"\nLama Sewa (max 3 hari) : \n";cin>>hari;
total = hari*9000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 2 :
cout<<"2. The Mummy: Tomb of the Dragon Emperor (2008)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*5000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 3 :
cout<<"3. Underworld: Evolution (2006)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*5000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 4 :
cout<<" 4. Rise of the Lycans (2009)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*5000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 5 :
cout<<"5. War (2007)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*6000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 6 :
cout<<"6. Bandidas (2006)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*6000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 7 :
cout<<"7. Domino (2005)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*6000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 8 :
cout<<"8. Enough (2002)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*6000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 9 :
cout<<"9. Cradle of Life (2003)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*5000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 10 :
cout<<"10. V for Vendetta (2005)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*5000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
}}
if (pil=='b')
{
cout<<"\t\t66**********************99\n";
cout<<"\t\t||\tCOMEDY MOVIE\t||\n";
cout<<"\t\t99**********************66\n\n";
cout<<"\t 1. Bottle Shock (2008) \n";
cout<<"\t 2. Something's Gotta Give (2003)\n";
cout<<"\t 3. It's Complicated (2009)\n";
cout<<"\t 4. Cocoon (1985)\n";
cout<<"\t 5. Charlie and the Chocolate Factory (2005)\n";
cout<<"\t 6. Bedtime Stories (2008)\n";
cout<<"\t 7. Meet Dave (2008)\n";
cout<<"\t 8. Beverly Hills Chihuahua (2008)\n";
cout<<"\t 9. A Prairie Home Companion (2006)\n";
cout<<"\t 10.The History Boys (2006) \n";
cout<<"\n Pilihan Film yang Disewa : ";cin>>film;
switch(film)
{
case 1 :
cout<<"\n1. Bottle Shock (2008)\n";
cout<<"\nLama Sewa (max 3 hari) : \n";cin>>hari;
total = hari*8000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 2 :
cout<<"2. Something's Gotta Give (2003)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*8000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 3 :
cout<<"3. It's Complicated (2009)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*8000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 4 :
cout<<" 4. Cocoon (1985)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*8000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 5 :
cout<<"5. Charlie and the Chocolate Factory (2005)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*8000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 6 :
cout<<"6. Bedtime Stories (2008)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*8000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 7 :
cout<<"7. Meet Dave (2008)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*8000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 8 :
cout<<"8. Beverly Hills Chihuahua (2008)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*8000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 9 :
cout<<"9. A Prairie Home Companion (2006)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*8000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 10 :
cout<<"10.The History Boys (2006)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*8000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
}}
if (pil=='c')
{
cout<<"\t\t66**********************99\n";
cout<<"\t\t||\tDRAMA MOVIE\t||\n";
cout<<"\t\t99**********************66\n\n";
cout<<"\t 1. Brokeback Mountain (2005) \n";
cout<<"\t 2. Far From Heaven (2002)\n";
cout<<"\t 3. Gods and Monsters (1998)\n";
cout<<"\t 4. Midnight Cowboy (1969)\n";
cout<<"\t 5. Milk    (2008)\n";
cout<<"\t 6. Last Legion (2007)\n";
cout<<"\t 7. Cleopatra (1963)\n";
cout<<"\t 8. Kingdom of Heaven (2005)\n";
cout<<"\t 9. Code of the Templars (2004)\n";
cout<<"\t 10.King Arthur (2004)\n";
cout<<"\n Pilihan Film yang Disewa : ";cin>>film;
switch(film)
{
case 1 :
cout<<"\n1. Brokeback Mountain (2005)\n";
cout<<"\nLama Sewa (max 3 hari) : \n";cin>>hari;
total = hari*12000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 2 :
cout<<"2. Far From Heaven (2002)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*12000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 3 :
cout<<"3. Gods and Monsters (1998)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*12000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 4 :
cout<<" 4. Midnight Cowboy (1969)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*12000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 5 :
cout<<"5. Milk    (2008)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*12000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 6 :
cout<<"6. Last Legion (2007)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*12000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 7 :
cout<<"7. Cleopatra (1963)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*12000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 8 :
cout<<"8. Kingdom of Heaven (2005)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*12000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 9 :
cout<<"9. Code of the Templars (2004)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*12000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 10 :
cout<<"10.King Arthur (2004)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*12000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
}}
if (pil=='d')
{
cout<<"\t\t66**********************99\n";
cout<<"\t\t||\tDOCUMENTARY MOVIE\t||\n";
cout<<"\t\t99**********************66\n\n";
cout<<"\t 1. MGM: When the Lion Roars (1992)\n";
cout<<"\t 2. Who Killed the Electric Car? (2006)\n";
cout<<"\t 3. Religulous (2008)\n";
cout<<"\t 4. Super Size Me (2004)\n";
cout<<"\t 5. Planet Earth (2006)\n";
cout<<"\t 6. Sicko (2007)\n";
cout<<"\t 7. Noam Chomsky: Rebel without a Pause (2003)\n";
cout<<"\t 8. A Converstion with Koko (1999)\n";
cout<<"\t 9. Earth (2007)\n";
cout<<"\t 10.Citizen King (2001)\n";
cout<<"\n Pilihan Film yang Disewa : ";cin>>film;
switch(film)
{
case 1 :
cout<<"\n1. MGM: When the Lion Roars (1992) \n";
cout<<"\nLama Sewa (max 3 hari) : \n";cin>>hari;
total = hari*10000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 2 :
cout<<"2. Who Killed the Electric Car? (2006)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*10000;
cout<<"Total Pembayaran :\n"<<total<<endl;
break;
case 3 :
cout<<"3. Religulous (2008)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*10000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 4 :
cout<<" 4. Super Size Me (2004)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*10000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 5 :
cout<<"5. Planet Earth (2006)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*10000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 6 :
cout<<"6. Sicko (2007)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*10000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 7 :
cout<<"7. Noam Chomsky: Rebel without a Pause (2003)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*10000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 8 :
cout<<"8. A Converstion with Koko (1999)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*10000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 9 :
cout<<"9. Earth (2007)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*10000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 10 :
cout<<"10.Citizen King (2001)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*10000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
}}
if (pil=='e')
{
cout<<"\t\t66**********************99\n";
cout<<"\t\t||\tROMANCE MOVIE\t||\n";
cout<<"\t\t99**********************66\n\n";
cout<<"\t 1. America's Sweethearts (2001)\n";
cout<<"\t 2. A Cinderella Story (1998)\n";
cout<<"\t 3. Wedding Daze (2006)\n";
cout<<"\t 4. The Heartbreak Kid (2007)\n";
cout<<"\t 5. Say Anything (1989)\n";
cout<<"\t 6. 10 Things I Hate about You (1999)\n";
cout<<"\t 7. Imagine Me & You (2005)\n";
cout<<"\t 8. She's the Man (2006)\n";
cout<<"\t 9. Miss Pettigrew Lives for a Day (2008)\n";
cout<<"\t 10.The Ramen Girl (2008) \n";
cout<<"\n Pilihan Film yang Disewa : ";cin>>film;
switch(film)
{
case 1 :
cout<<"\n1. America's Sweethearts (2001)\n";
cout<<"\nLama Sewa (max 3 hari) : \n";cin>>hari;
total = hari*13000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 2 :
cout<<"2. A Cinderella Story (1998)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*13000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 3 :
cout<<"3. Wedding Daze (2006)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*13000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 4 :
cout<<" 4. The Heartbreak Kid (2007)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*13000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 5 :
cout<<"5. Say Anything (1989)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*13000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 6 :
cout<<"6. 10 Things I Hate about You (1999)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*13000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 7 :
cout<<"7. Imagine Me & You (2005)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*13000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 8 :
cout<<"8. She's the Man (2006)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*13000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 9 :
cout<<"9. Miss Pettigrew Lives for a Day (2008)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*13000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 10 :
cout<<"10.The Ramen Girl (2008) \n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*13000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
}}
if (pil=='f')
{
cout<<"\t\t66**********************99\n";
cout<<"\t\t||\tHORROR MOVIE\t||\n";
cout<<"\t\t99**********************66\n\n";
cout<<"\t 1. Children of the Corn (1984)\n";
cout<<"\t 2. Devil's Backbone (2001)\n";
cout<<"\t 3. Mirrors (2008) \n";
cout<<"\t 4. Darkness (2004)\n";
cout<<"\t 5. Dark Water (2005)\n";
cout<<"\t 6. The Messengers (2007)\n";
cout<<"\t 7. Blood and Chocolate (2007)\n";
cout<<"\t 8. Van Helsing (2004) \n";
cout<<"\t 9. Halloween (1978)\n";
cout<<"\t 10.From Hell (2001)\n";
cout<<"\n Pilihan Film yang Disewa : ";cin>>film;
switch(film)
{
case 1 :
cout<<"\n1. Children of the Corn (1984)\n";
cout<<"\nLama Sewa (max 3 hari) : \n";cin>>hari;
total = hari*15000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 2 :
cout<<"2. Devil's Backbone (2001)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*15000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 3 :
cout<<"3. Mirrors (2008) \n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*15000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 4 :
cout<<" 4. Darkness (2004)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*15000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 5 :
cout<<"5. Dark Water (2005)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*15000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 6 :
cout<<"6. The Messengers (2007)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*15000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 7 :
cout<<"7. Blood and Chocolate (2007)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*15000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 8 :
cout<<"8. Van Helsing (2004) \n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*15000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 9 :
cout<<"9. Halloween (1978)\n";
cout<<"\n Lama Sewa (max 3 hari): ";cin>>hari;
total=hari*15000;
cout<<"Total Pembayaran :"<<total<<endl;
break;
case 10 :
cout<<"10.From Hell (2001)\n";
cout<<"\nLama Sewa (max 3 hari): ";cin>>hari;
total=hari*15000;
cout<<"Total Pembayaran :\n"<<total<<endl;
break;
}
}
cout<<"NB.\t1. Maksimal Peminjaman DVD hanya 3 keping.\n";
cout<<"\t2. Denda melebihi batas sewa Rp 3000/hari.";
}



JANGAN LUPA COMMENT DAN SHARE YA :)

{ 2 komentar... read them below or Comment }

Copyright © Welcome here ~ | Green Minimalist Theme |Powered by Blogger | Designed by Johanes DJ