|
From: David M. <ci...@ya...> - 2002-04-19 13:24:27
|
An array is not dynamic, the value you pass it at
initalization must be a constat of some sort.
if 'i' were to change during the program some weird
voodoo (the program will crash,the world will end,etc.)
all this will hapen because it cannot change the size of an
array at runtime(reason no. 1 linked lists were created)
> >From: "Anon" <an...@pu...>
> >To: <dev...@li...>
> >Subject: [Dev-C++] Ansi compatible?
> >Date: Thu, 18 Apr 2002 11:50:11 +0530
> >
> >Hey!
> >Can anyone please tell me if the following code is ANSI
> compatible? It
> >compiles fine with DevC++ but throws up an error in Borland 5.0
> >
> >#include <iostream.h>
> >#include <stdlib.h>
> >
> >int main()
> >{
> > int i=10;
> > int arr[i]; //can it do accept Integer variable
> > system("PAUSE");
> > return 0;
> >}
> >
> >My classmates say that this is a violation of ANSI standard.
> >
> >
> >---
> >Outgoing mail is certified Virus Free.
> >Checked by AVG anti-virus system (http://www.grisoft.com).
> >Version: 6.0.346 / Virus Database: 194 - Release Date: 4/10/2002
>
>
> _________________________________________________________________
> Chat with friends online, try MSN Messenger:
> http://messenger.msn.com
>
>
> _______________________________________________
> Dev-cpp-users mailing list
> Dev...@li...
> https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
__________________________________________________
Do You Yahoo!?
Yahoo! Tax Center - online filing with TurboTax
http://taxes.yahoo.com/
|