Re: char**
- From: MN <mazouz.nezhate@xxxxxxxxx>
- Date: Sat, 30 Aug 2008 05:07:54 -0700 (PDT)
On Aug 30, 2:55 pm, Richard Heathfield <r...@xxxxxxxxxxxxxxx> wrote:
MN said:
I have a question :
How to understand the mean of char** type ?
char is a type - objects of that type are 1 byte in size and can contain as
their value any single member of the execution character set.
char * is a type - objects of that type are sizeof(char *) bytes in size,
and can contain as their value the address of a single char.
char ** is a type - objects of that type are sizeof(char **) bytes in size,
and can contain as their value the address of a single char *.
What is the question behind the question?
--
Richard Heathfield <http://www.cpax.org.uk>
Email: -http://www. +rjh@
Google users: <http://www.cpax.org.uk/prg/writings/googly.php>
"Usenet is a strange place" - dmr 29 July 1999
the question is :
I have a function which returns an array of chars with 2 dimensions.
The size of array is dynamically changed by malloc.
To return this array I must declare it as an extern in the header file
like this: extern char** array.
if I use extern char* array, I get error.
.
- Follow-Ups:
- Re: char**
- From: Barry Schwarz
- Re: char**
- From: pete
- Re: char**
- References:
- Re: char**
- From: Richard Heathfield
- Re: char**
- Prev by Date: Re: K&R Exercise 6-2
- Next by Date: Re: Problems With Global Variables (memory allocations)
- Previous by thread: Re: char**
- Next by thread: Re: char**
- Index(es):
Relevant Pages
|