Trouble in study time program

the question is
Write a program that computes the average number of hours a student spends on programing and on Biology over a long week end. Your program should ask the user how many students there are as well as the number of days in the long week. For each student the user has to enter the number of hours spent programing and the number of hours spent studying Biology.

Your program should output the average number of hours spent programming as well as studying Biology for each student. Your program should also output which subject the student spent the most time on.

The program i have so far is this but im a bit lost

#include <iostream>
#include <cmath>
#include <iomanip>
#include <string>

using namespace std;

int main()
{

int days=0, student=0, bio=0, pro=0,total=0;

cout<<"please enter the number of students"<<endl;
cin>>student;

cout<<"please enter number of days in week"<<endl;
cin>>days;

cout<<"homework survey"<<endl;
cout<<"how many hours do you spend on biology and programming a day"<<endl;
for(int i=1;i<=student;i++)
{
cout<<"how many hours do you spend on biology and programming a day for student #" << i <<endl;
cin>>bio;
cin>>pro;

if(student -= -1)
return 0;
cout<<endl;

switch(bio)
{
case 1:
bio++;
break;

default:
cout<<"please enter in a valid number"<<endl;
}

switch (pro)
{
case 1:
pro++;
break;

default:
cout<<"please enter in a valid number"<<endl;
}
cout<<endl;

cout<<







return 0;
}
design from beginning:
you have many days
many students
and two subject for each students.

you can control the days via a loop (for or while).
you can put students in an array. each cell for one student.
you can put pro and bio in separated arrays. you can match indexes to match subjects to students.

------
or you can make a struct for student with to value for subjects then make an array for sutudents.
-------
then you can loop over student (or and subjects) array and calculate
Topic archived. No new replies allowed.