Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is the difference between char a[] = "string"; and
char *p = "string"; ?

Answer Posted / ashwin kumar

just one word i can say that
a[] is static memory allocation ( we cant increase size of
array while execution of program )
*p is a dynamic memory allocation ( where we can use
according to our requirement while execution )

their may be a waste age of memory and also their may be
limitaion of elements in array.

memory will not be wasted and size depends up on our
require ment in pointes

i hope its may be one of the defferance

if thier is any feed back or my answer is wrong plz write
to molugu.aswin@gmail.com

Is This Answer Correct ?    6 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why c is called a mid level programming language?

1034


What is the easiest sorting method to use?

1110


What is the value of uninitialized variable in c?

986


What are the advantages of using macro in c language?

1081


how we can make 3d venturing graphics on outer interface

4742


What does *p++ do?

983


Are enumerations really portable?

988


Does sprintf put null character?

993


HOW TO SOLVE A NUMERICAL OF LRU IN OS ??????

2646


to find the closest pair

2294


typedef enum { html, java, javascript, perl, cgi } lang;The above statement defines a : a) Union b) User defined type c) Enumerated variable d) none

1169


What is hash table in c?

985


What is the advantage of an array over individual variables?

1192


An arrangement of information in memory in such a way that it can be easily accessed and processed by a programming language a) string b) data structure c) pointers d) array

1097


A c program to display count values from 0 to 100 and flash each digit for a secong.reset the counter after it reaches 100.use for loop,. pls guys hepl me.. :(

2213