Wednesday, October 19, 2011

4.9

this is for programming exercise 4.9 

testing the code.

#include
using namespace std;

int main()
{
    int score = 0, highestScore = 0,lowestScore=100,student;
    cout<<"Enter number of student:";
    cin>>student;
   
    for(int i=0;i
    {
            cout<<"Enter score:";
            cin>>score;
              
               if (score> highestScore)
               highestScore=score;
              
               if (score< lowestScore)
               lowestScore=score;
              
    }
   
    cout<<"Highest score"<<
    cout<<"Lowest score"<<
   
    system("pause");
    return 0;
   
}
              
   

.: Syukran, moga sama2 menambah ilmu =] :.

0 kalam anda: