How To Find Errors In Dev C++

Dev C++ Error 1073741819

Dev

How To Find Errors In Dev C Windows 10

May 10, 2006  program that automatically finds C syntax errors? Admittedly such software can be very expensive, but maybe someone will let you use theirs. Isn't 'a program that automatically finds C syntax errors' called a compiler? Not all C compilers are expensive, many are free. The lack of senses of humor in this NG continues to amaze me. The question about Dev-Pascal (Free Pascal version) not being able to find the MAIN.ICO icon has come up quite a lot recently. When you create a new project with Dev-Pascal, it creates a resource that contains only one thing; the path to MAIN.ICO but for some reason it can't find it (it is located in the Dev-Pascal Icon folder).

How To See Errors In Dev C++

this is my code of McD simulation
but i can't find the error..
if can, i don't want the header file because its difficult for me to find the error..
1 C:Dev-Cppincludec++3.4.2backwardiostream.h:31, from C:Documents and SettingsAdministratorMy Documentsdatastructuredmain.cpp In file included from C:/Dev-Cpp/include/c++/3.4.2/backward/iostream.h:31, from C:Documents and SettingsAdministratorMy Documentsdatastructuredmain.cpp
1 C:Documents and SettingsAdministratorMy Documentsdatastructuredmain.cpp from C:Documents and SettingsAdministratorMy Documentsdatastructuredmain.cpp
14 C:Documents and SettingsAdministratorMy Documentsdatastructuredmain.cpp `queue' has not been declared
14 C:Documents and SettingsAdministratorMy Documentsdatastructuredmain.cpp `queue' has not been declared
can someone solve my problem
this is my coding for main.cpp
#include <iostream.h>
#include <stdlib.h>
#include <time.h>
#include <conio.h>
#include <cstring>
#include <iomanip.h>
#include <fstream.h>
//#include 'queue.h'
//#include 'list.h'
using namespace std;
const int Total_Minutes=1440;
queue::queue() (const T &id ,const int a_time ,const int s_time)
{
//void Simulation ();
class McDonalds
{
private:
int Customer;
int Customer_Id;
int Arrival_Time;
int Current_Service_Time;
int Hour_Waiting_Time;
int Total_Customers;
int Insert_Node;
McDonalds() { } // private default constructor
public:
McDonalds() : Customer_Id(0) , Arrival_Time(0), Hour_Waiting_Time(0) , Current_Service_Time(0),
Total_Customers(0)
{ }
void Simulation();
};
void McDonalds::Simulation()
{
int Customer_Arrival_Time=1, Total_Waiting=0 , Service_Time=0 ,j=0;
float Average_Waiting_Time=0;
Arrival_Time=1;
srand(time(0));
for (int minute=1 ; minute<=Total_Minutes ; minute+=Customer_Arrival_Time)
{
if (minuteArrival_Time)
{
++Customer_Id;
Current_Service_Time=(rand()%4+1) + 4;
Customer.Insert_Node(Customer_Id,Customer_Arrival_Time,Current_Service_Time);
Service_Time+=Current_Service_Time;
if (Service_Time>1440)
break;
else
Hour_Waiting_Time+=Current_Service_Time-Customer_Arrival_Time;
Arrival_Time=(rand()%3+1)+minute;
Customer_Arrival_Time=Arrival_Time-minute;
}
}
Total_Customers+=Customer_Id;
Total_Waiting+=Hour_Waiting_Time;
Average_Waiting_Time=Total_Waiting/Customer_Id;
outFile<<'--------------------------------------------------------------'<<endl;
outFile<<' M C D O N A L D S '<<endl;
outFile<<'--------------------------------------------------------------'<<endl;
outFile<<' 2 4 - H o u r S i m u l a t i o n'<<endl;
outFile<<'--------------------------------------------------------------'<<endl<<endl;
outFile<<'=> TOTAL CUSTOMERS : '<<Customer_Id<<endl<<endl;
outFile<<'=> TOTAL WAITING TIME (in minutes) : '<<Total_Waiting<<endl<<endl;
outFile<<'=> TOTAL WAITING TIME (in hour) : '<<Total_Waiting/60<<endl<<endl;
outFile<<'=> AVERAGE WAITING TIME (per customer): '<<Average_Waiting_Time<<endl<<endl;
outFile<<'--------------------------------------------------------------'<<endl<<endl;
if ((Average_Waiting_Time)>3)
outFile<<'The management has to increase the number of counters'<<endl<<endl;
else
outFile<<'The management need not increase the number of counters'<<endl<<endl;
outFile<<'--------------------------------------------------------------'<<endl;
Customer.Display_List(outfile);
}
int main(int argc , char* args[])
{
if (argc<1)
{
cerr<<'INVALID NUMBER OF ARGUMENTS';
return 1;
}
/*open file stream for the input and output
ofstream outFile(args[1], ios::out);
checks that the output file is open or not
if (!outFile)
{
cerr<<'unable to open the output file'<<endl;
return 2;
}
*/
string line;
ifstream myfile1 ('queue.h');
if (myfile1.is_open())
{
while (! myfile1.eof() )
{
getline (myfile1,line);
cout << line << endl;
}
myfile1.close();
}
else cout << 'Unable to open file';
string line;
ifstream myfile1 ('queue.h');
if (myfile1.is_open())
{
while (! myfile1.eof() )
{
getline (myfile1,line);
cout << line << endl;
}
myfile1.close();
}
else cout << 'Unable to open file';
// McDonalds Customers;
// Customers.Simulation(outFile);
system ('pause');
return 0;
}
int class (int T, int List);
{
template <class T>
class List;
//-------------------------------- N O D E C L A S S -----------------------------------
template <class T>
class Node
{
friend class List<T>;
public:
Node()
{
Service_Time=0;
Arrival_Time=0;
next=NULL;
}
Node(const T &id ,const int a_time ,const int s_time)
{
Customer_Id=id;
Service_Time=s_time;
Arrival_Time=a_time;
next=NULL;
}
Node(const T &id, const int a_time ,const int s_time , Node<T> *n)
{
Customer_Id=id;
Service_Time=s_time;
Arrival_Time=a_time;
next=n;
}
private:
T Customer_Id;
int Service_Time;
int Arrival_Time;
Node<T> *next;
};
//-------------------------------- L I S T C L A S S --------------------------------------
template <class T>
class List
{
public:
List()
{
Head=NULL;
Tail=NULL;
size=0;
}
List(const List<T> &);
~List();
void Delete_List();
void Insert_Node(const T & , const int , const int);
void Delete_Node(const T &);
void Display_List(ofstream&) const;
int Get_size() const
{
return size;
}
List& operator = (const List<T> &);
private:
Node<T> *Head;
Node<T> *Tail;
int size;
};
template <class T>
List<T>::~List()
{
Delete_List();
size=0;
}
template <class T>
void List<T>::Delete_List()
{
if (Head!=NULL)
{
Node<T> *currentptr=Head;
Node<T> *tempptr;
while (currentptr!=0)
{
tempptr=currentptr;
currentptr=currentptr->next;
delete tempptr;
}
}
Head=NULL;
}
template <class T>
void List<T> :: Insert_Node(const T &id , const int a_time ,const int s_time)
{
Node<T> *newptr=new Node<T>(id , a_time , s_time);
assert(newptr!=0);
if (Head0)
{
Head=newptr;
Tail=newptr;
}
else
{
Tail->next=newptr;
Tail=newptr;
}
size++;
}
template <class T>
void List<T> :: Delete_Node(const T &id)
{
if (Head0)
{
cout<<'n error : THE LIST IS EMPTY !';
}
else
{
Node<T> *Fatherptr=Head;
Node<T> *Sonptr=Head->next;
if (Fatherptr->Customer_Idid)
{
Head=Head->next;
}
else
{
while (Sonptr!=NULL)
{
if (Sonptr->Customer_Idid)
{
Fatherptr->next=Sonptr->next;
}
Sonptr=Sonptr->next;
Fatherptr=Fatherptr->next;
}
}
}
}
template <class T>
void List<T> :: Display_List(ofstream& outFile) const
{
if (Head0)
outFile<<'error : THE LIST IS EMPTY ! n';
else
{
Node<T> *currentptr=Head;
outFile<<'nnttC U S T O M E R L I S T'<<endl;
outFile<<'tt------------------------'<<endl<<endl;
while (currentptr !=NULL)
{
outFile<<'Customer Id :'<<currentptr->Customer_Id<<endl;
outFile<<'---------------------'<<endl<<endl;
outFile<<'Arrival Time :'<<currentptr->Arrival_Time<<endl;
outFile<<'Service Time :'<<currentptr->Service_Time<<endl<<endl;
currentptr=currentptr->next;
}
}
}
template <class T>
List<T> :: List(const List<T> &original)
{
size=original.size;
Node<T> *ptr=original.Head;
Node<T> *newptr , *lastptr;
while(ptr!=NULL);
{
newptr=new Node<T>(ptr->Customer_Id , ptr->Waiting_Time , ptr->Service_Time);
assert(newptr!=0);
if (Head0)
Head=newptr;
else
lastptr->next=newptr;
lastptr=newptr;
ptr=ptr->next;
}
}
template <class T>
List<T>& List<T> :: operator=(const List<T> &original)
{
if (this!=&original)
{
deleteList();
size=original.size;
Head=0;
Node<T> *ptr=original.Head;
Node<T> *newptr , *lastptr;
while(ptr!=0);
{
newptr=new Node<T>(ptr->Customer_Id , ptr->Waiting_Time , ptr->Service_Time);
assert(newptr!=0);
if (Head0)
Head=newptr;
else
lastptr->next=newptr;
lastptr=newptr;
ptr=ptr->next;
}
}
return ptr;
}
newptr