Sabtu, 01 Desember 2012

program c++

//Contoh program menghitung biaya kuliah berdasarkan jumlah SKS. (soal UAS semester 2)

#include <iostream.h>
#include <conio.h>
#include <stdio.h>
struct mahasiswa
{
char nama[25];
char nim[11];
int sks;
float biaya;
};


void main()
{
clrscr();

mahasiswa mhs;
cout<<"Nama       : "; cin.getline(mhs.nama,25);
cout<<"NIM        : "; cin.getline(mhs.nim,11);

mhs.sks;
cout<<"Jumlah SKS : "; cin>>mhs.sks;
mhs.biaya=(30000.00*mhs.sks);
cout<<"Biaya           : "<<mhs.biaya<<endl;

cout<<endl;
cout<<endl;
getch();
}

1 komentar:

  1. Borgata Hotel Casino & Spa - JTR Hub
    Located in herzamanindir Atlantic herzamanindir.com/ City, Borgata Hotel 출장안마 Casino & Spa offers the finest in amenities and entertainment. It https://vannienailor4166blog.blogspot.com/ also provides a seasonal outdoor swimming

    BalasHapus