The following errors popped up upon compiling is there a way to fix this in dev c++ ???
Please resond here or to <snip> Thank you. How to download a vst to fl studio.
Please resond here or to <snip> Thank you. How to download a vst to fl studio.
Install Dev-C. I installed from the Version 4.9.9.2 Setup File. Download graphics.h to the include/ subdirectory of the Dev-C directories. Download libbgi.a to the lib/ In order to use the WinBGIm subdirectory of the Dev-C directories. Whenever you #include in a program, you must instruct the linker to link in certain libraries. Jan 08, 2018 How to Reset Dev C default Settings. Restore default settings in Dev C. Dev C plus plus is an IDE for writing programs in C and C. Learn how to reset default settings in Dev C.
Lij mickael cooke studio download mp4. Dev-Cpplibgccmingw323.4.2includesyslimits.h [Warning] #include_next is a GCC extension <- I have mingw installed from the included updater in dev c++
How To Find Errors In Dev C Online
Tcp receive window auto-tuning windows 2012. C:Dev-Cppincludesystypes.h ISO C++ does not support `long long' <-- this one came up alot
How To Check Error In Dev C++
Edited by ~s.o.s~: Email ID snipped; keep it on site.
- 4 Contributors
- forum 6 Replies
- 256 Views
- 1 Day Discussion Span
- commentLatest Postby jaskijLatest Post
Ancient Dragon5,243
C# linux compiler. You can't fix it with that compiler because that compiler version is too old. Get free Code::Blocks with MinGW ('>link here), which is current.
Edited by Ancient Dragon: n/a
![Dev Dev](/uploads/1/2/6/2/126251635/105795869.jpg)
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
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