|
From: James G. <Jam...@Cl...> - 2001-01-11 09:15:01
|
Try
int entry_var new int[size_of_entry];
You still have to specify what the type of entry_var is.
Regards,
James.
-----Original Message-----
From: Alan Thomas [mailto:ala...@3n...]
Sent: Thursday, January 11, 2001 2:56 AM
To: dev...@li...
Subject: Re: [Dev-C++] dynamic array
I could not compile the code below. Thanks, Alan
From: <mailto:ste...@ge...> ste...@ge...
Subject: Re: [Dev-C++] dynamic array
Date: Wed, 10 Jan 2001 05:12:37 -0800
entry_var new int[size_of_entry];
if(!entry_var)
{
cout << "Unable to allocate memory!";
getch();
exit(-1);
}
delete(entry_var);
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
This electronic message and any attachment is intended to be
read by the named addressee(s) only.
Any other recipient should be aware that its contents may be
legally privileged and/or confidential and that its use,
disclosure, copying or distribution may be unlawful.
Unless you are a named addressee, please delete this message
Whilst C. & J. Clark International Limited has taken steps
to prevent the transmission of computer viruses with electronic mail,
responsibility for screening incoming messages and the risk of such
transmission and its consequences lies with the recipient.
C. & J. Clark International Limited
Registered in England and Wales
Company No. 141015
Registered Office: 40 High Street, Street, Somerset BA16 0YA
Telephone: +44 (0) 1458 443131
Fax: +44 (0) 1458 447547
|