Important : Please do NOT wait for job alert emails. Sometimes, we may NOT be able to send emails due to server problems. So always directly visit www.ChetanaSforum.com to view all jobs DAILY, so that you will NOT miss important Walk-In. We suggest you to LIKE OUR FACEBOOK PAGE to keep track of new jobs through Facebook.
Home    Register    Facebook    Post Jobs for Free    Jobs By Location    Exclusive Off-Campus    2013 Batch   Job Fairs    JavaKen.com    TestingKen.com
Infosys, TCS, Yahoo & Amazon are hiring. Register Now ! Submit Resume to 50,000 Recruiters LIKE our FaceBook Page
IPB

Welcome Guest ( Log In | Register )




Tags
This content has not been tagged yet
 
Reply to this topicStart new topic
> c++
akanksha singhai
post Feb 5 2011, 02:54 PM
Post #1


Newbie
*

Group: Members
Posts: 3
Joined: 30-January 11
Member No.: 539,229





Infosys, TCS, Yahoo & Amazon are hiring. Register Now !
If you like this post, please share it to help others.


difference b/w char*x and char x[]

Submit Latest Resume Now !



Go to the top of the page
 
+Quote Post
sureshgummalla
post Feb 5 2011, 04:33 PM
Post #2


Newbie
*

Group: Members
Posts: 1
Joined: 30-July 10
Member No.: 384,216




QUOTE (akanksha singhai @ Feb 5 2011, 02:54 PM) *
difference b/w char*x and char x[]

In char*x, the variable x is a pointer of character type(a pointer is variable which points(represent) to some memory location)
in char x[] the x is a array of character type (like string). biggrin.gif

Go to the top of the page
 
+Quote Post
sean lopez
post Feb 7 2011, 09:45 AM
Post #3


Advanced Member
***

Group: Members
Posts: 241
Joined: 1-November 08
Member No.: 201,082




I hope this source will help you
http://bytes.com/topic/c/answers/127619-di...een-char-char-x



--------------------
Go to the top of the page
 
+Quote Post
Alice Coope
post Feb 28 2011, 03:09 PM
Post #4


Advanced Member
***

Group: Members
Posts: 45
Joined: 3-November 10
Member No.: 463,857




You can check out this discussion-

http://stackoverflow.com/questions/4120658...-char-and-char1



--------------------
Go to the top of the page
 
+Quote Post
Alice Coope
post Feb 28 2011, 03:09 PM
Post #5


Advanced Member
***

Group: Members
Posts: 45
Joined: 3-November 10
Member No.: 463,857




You can check out this discussion-

http://stackoverflow.com/questions/4120658...-char-and-char1



--------------------
Go to the top of the page
 
+Quote Post
RupinKhandelwal
post Aug 19 2011, 06:13 PM
Post #6


Newbie
*

Group: Members
Posts: 2
Joined: 15-August 11
Member No.: 742,470




QUOTE (akanksha singhai @ Feb 5 2011, 03:54 PM) *
difference b/w char*x and char x[]



In char * x is the pointer pointing to the intial memory location and size of the pointer is not fix.
but in char x[] we have to initialize the array of fix size.

Go to the top of the page
 
+Quote Post
Mr. Sumit kumar
post Dec 1 2011, 12:52 PM
Post #7


Member
**

Group: Members
Posts: 11
Joined: 30-December 10
From: Jaipur
Member No.: 510,009




The difference here is that
char *x puts in the read-only parts of the memory and making x a pointer to that, making any writing operation on this memory illegal. While doing:
char x[] puts in read-only memory and copies to newly allocated memory on the stack.


_____________
SEO Swindon

Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 18th May 2013 - 02:49 PM