www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/08/10/19:09:02

From: Leon AT caresystems DOT com DOT au
To: djgpp AT delorie DOT com
Date: Fri, 11 Aug 2000 09:18:07 +1000
MIME-Version: 1.0
Subject: Re: a bit about arrays...
Message-ID: <3993C4CF.27976.2F4F0@localhost>
In-reply-to: <SEik5.4799$aK5.80126@news1.online.no>
X-mailer: Pegasus Mail for Win32 (v3.12c)
Reply-To: djgpp AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On 9 Aug 2000, at 22:00, Vermin wrote:

> I've got two questions concerning arrays:
> 
> <1>
> What's the difference between
> 
> char anArray[100];
> 
> and
> 
> char *anArray;
> anArray = new (char)[100];
> 

first creates array of 100 char
second creates array of 100char on free store
first - anArray is a constant pointer.
seond - anArray is _not_ a constant pointer.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019