Sunday, November 18, 2012

Modul_5: LOOPING

Modul_5:  LOOPING
Nama     : Deab Sina
NIM      : 49012078
Jurusan   : D4 TMD ITB Batch 6

This is video about: Looping


 

Link to this video:


Source Code:

// I want to tell you about if/else statement
#include <iostream>
using namespace std;

int main()
{
    int score; // declare int virable score
    cout<<"========================================"<<endl;
    cout<<"                            if/else statement"<<endl;
    cout<<"========================================"<<endl;
    cout<<"Please insert score = ";
    cin>>score;
    cout<<"----------------------------------------"<<endl;

    if ( score >=90 )
    {
        cout<<"You are grade A"<<endl;
    }
    else if ( score >=80 )
    {
        cout<<"You are grade B"<<endl;
    }
    else if ( score >=70 )
    {
        cout<<"You are grade C"<<endl;
    }
    else if ( score >=60 )
    {
        cout<<"You are grade D"<<endl;
    }
    else
    {
        cout<<"You are grade E"<<endl;
    }
    system("pause");
    return 0;
}

Show detail about this Modul.

https://docs.google.com/open?id=0B0z1Cq4I6LpQbG14ZnpCTlBkejQ

No comments:

Post a Comment