I'm new to programming and after I have learned the basics of C I don't understand the following keywords:
(*char)
a -> b
char**
I'm new to programming and after I have learned the basics of C I don't understand the following keywords:
(*char)
a -> b
char**
You need a C book! I'll tell you what it means though:
(char)
is the char
variable type wrapped in parenthesis. You do this when you are typecast
ing.
a -> b
is how you access a structure field if a
is a pointer to a structure and b
is the variable name of the field.
char *
is how you declare something to be a pointer to a char, as in char *c
.
They could have other meanings too. Depends on the context.
You edited your question!
(*char)
is how you'd dereference a variable named char
if you could, but you can't because char
is a keyword.
a -> b
is how you access a structure field if a
is a pointer to a structure and b
is the variable name of the field.
char **
is a pointer to a pointer to a char
. You see this when you have an array of strings.
In order, they are:
dereferenced char
pointer (read "value at")
b
, an element of something pointed to by a
A pointer to a char*
, or a pointer to a pointer to a char