My goal is to try and create a program that takes in grades in percents and multiply it with their weight value (either in decimal form or percent form). The equation is basically:

Overall grade = (grade1\*weightInDecimal1)+(grade2\*weightInDecimal2)+(grade3\*weightInDecimal3)+...

or 

Overall grade = (grade1\*weight%1)+(grade2\*weight%2)+(grade3\*weight%3)+...

---

Is there a way to store the inputs and then recall it later in the code? Or possibly a more efficient way?

I also want to try and make a dynamic array. I want to make a program that asks the user for how many assignments they have and makes an array based on that. That way it's not stuck at 4 assignments

```
#include <string>
#include <iostream>
using namespace std;
int main() {
    int numbers[4][2];
    for(int i=0;i<4;i++)
    {
       cout<<"Grade #"<<i<<endl;
       cin>>numbers[i][0];
       cout<<"Weight for grade #"<<i<<":"<<endl;
       cin>>numbers[i][1];
    }

    for (int i = 0; i<4; i++)
    {
        cout << "|" << numbers[i][0]*numbers[i][1]<< "|";
    }
    system ("PAUSE");
return 0;
}

```