Q:

Visual Studio C++ Issues

I always programmed on xcode, but after finally switching back to PC, I decided to use Visual studios; however, one problem I'm encountering is that it won't read my whole program at times.  For example.  I could have a program aht just displays "Hello", and it'll show that, but when I modify it, and add other things to the same program it won't recognize the rest of the program and when I build, and run it it'll just display "Hello", even though there's other lines of code. 
Here's a program I was trying write 
      #include <iostream>
#include <string>
#include <iomanip>

using namespace std;

void DisplayInput(string[], string[], char [], double[], double[], double[], int);
void Calculation(double, double, double, double[], double[], double, double, int);

int main()
{

    int const size = 3;
    string F_name[size], L_name[size];
    char Mi[size];
    double HoursWorked[size], Rate[size], Gross[size], Net[size];
    double StateTax, FederalTax, UnionFees, Sum, Avg;

    DisplayInput(F_name, L_name, Mi, HoursWorked, Rate, Gross,  size);
    Calculation(StateTax, FederalTax, UnionFees, Gross, Net, Sum, Avg, size);

    system("pause");
}

void DisplayInput(string F_name[], string L_name[], char Mi[], double HoursWorked[], double Rate[], double Gross[], int size)
{

    for (int i = 0; i < size; i++)
    {
        cout << " What's your first name " << endl;
        cin >> F_name[i];

        cout << "What's youtr last name? "  << endl;
        cin >> L_name[i];

        cout << "Enter your middle initials. "  << endl;
        cin >> Mi[i];

        cout << "How many hours did you work " << endl;
        cin >> HoursWorked[i];

        cout << "What is your hourly rate " << endl;
        cin >> Rate[i];

        double TimeHalf = 1.5;

        if (HoursWorked[i] < 0 || HoursWorked[i] > 60)
        {

            cout << " Wrong entry " << endl;

        }

        if (Rate[i] < 0 || Rate[i] > 50)
        {

            cout << "Number needs to be between 1 and 50 " << endl;

        }

        if (HoursWorked[i] <= 40)
        {

            Gross[i] = HoursWorked[i] * Rate[i];

        }

        else if (HoursWorked[i] > 40)
        {

            Gross[i] = HoursWorked[i] * (Rate[i] * TimeHalf);

        }

    }

}

    void Calculation(double StateTax, double FederalTax, double UnionFees, double Gross[], double Net[], double Sum, double Avg, int size)
    {

        StateTax = Gross[size] * 0.06;
        FederalTax = Gross[size] * 0.12;
        UnionFees = Gross[size] * 0.02;
        Net[size] = Gross[size] - (StateTax + FederalTax + UnionFees);

        Sum = +Gross[size];
        Avg = Sum / size;

    }

Yet when I run it, all I get is it asking me for the name, last name, and not the hours worked or rate, or any of the other lines of code I have in this program.  Any suggestions as to what might be causing this?  It's happened a few times this week, and  a work around was to save the program, and restart Visual Studios, but I did that again today and it's not working. 

A:

Sounds like you're project isn't building correctly
if you see this message box it means that there were errors in your code
if you just press yes, it will run the previously successfully compiled build.  so it sounds like you are doing this.  If you see this message, press no and check your code.