#include <iostream>
    #include <iomanip>
    #include <fstream
    using namespace std;

    const char Avail = '#';
    const char Taken = '*';
    const int r = 15;
    const int c = 30; 
    char SEATS[r][c];



    int main()
    {
        // Declarations for main
        ifstream inputPrices; 
        double seatPrices[15];
        int row;
        int column;
        double cost;
        int answer;
        int confirm; 
        int choice; 

Sorry, I forgot to list the lines, lines 125 - 127.

The easiest is probably to simply keep a variable, call it totalSales, to which you add the cost of each ticket that is bought, as they are bought. So, after line 25, you can add:

double totalSales = 0.0;

Then, right after line 104, you can add this line:

totalSales += seatPrices[row-1];

And finally, between line 125 and 126, you can add this line:

cout << "         Total of sales so far: " << totalSales << endl;

And that should do it.

The more complicated solution would be to loop through all the seats and check if they are Taken, and if so, add the cost of that ticket to the sum total.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.