Home > Software engineering >  Qt novice consult has in the main. Obj defined problem
Qt novice consult has in the main. Obj defined problem

Time:09-18

H header file movie.

Error: class ticket tick in mian. Obj redefinition, for help how to change urgent!!

#include
#include
#include
# define N 100
using namespace std;
Struct movie//define the date structure, storage of data
{
Int year;//in
Int the month;//
Int day;//day
Int hour;//
Int minute;//points
Int a datetime [100];//loading movie show times
String name;//movie name
int price;//ticket prices
Int a rest;//more ticket
String ting;
///hall
};
The class ticket {
Public:

Ticket (s);//the constructor
~ ticket ();//destructors
During void setData (int, int the month, int, int and int minute, string name, string ting, int price, int rest).
Int GetPrice ();//return price
String GetName ();//return the movie name
Void the Show ();//display all movie information
Void searchByName (string name);//by name lookup
During void searchByTime (int, int the month, int day);//by time to find the
Friend void print (int I);
//friend void the read ();//read the data
//void input ();
Private:
Movie tic [N].
int len; Number//movie
Int no;//serial number
Static int ticket_num;//serial number
Ticket * movies;
} tick;
Int the static ticket_num=10;//the first serial number

CodePudding user response:

Ticket * movies;
} tick;

Ticket * movies;
};

CodePudding user response:

//XXXX. H
# pragma once

The class XXXX
{

};


  • Related