Solved

Question

Posted on 2006-07-08
4
309 Views
Last Modified: 2012-05-05
Question: There is no difference between how C interprets 'x' and "X". Answer is FALSE.

WHY?
0
Comment
Question by:dandeliondream
  • 2
4 Comments
 
LVL 3

Author Comment

by:dandeliondream
ID: 17067082
sorry i mean...

There is no difference between how C interprets 'x' and "x".  Why?
0
 
LVL 24

Accepted Solution

by:
fridom earned 50 total points
ID: 17067091
There is a fundamental difference:
'x' is  char
"x" is a "string" correctly a field of chars and looks like this [x, '\0#]

So they completly different. Trying to hand over a char* instead of a char will give you
another idea about that.

Regards
Friedrich
0
 
LVL 11

Expert Comment

by:cup
ID: 17067144
It is easy to get confused about this if you come from a HTML, Javascript or Fortran background where primes ' and quotes " mean the same thing.
0
 
LVL 3

Author Comment

by:dandeliondream
ID: 17067280
Thanks fridom.
0

Featured Post

ScreenConnect 6.0 Free Trial

At ScreenConnect, partner feedback doesn't fall on deaf ears. We collected partner suggestions off of their virtual wish list and transformed them into one game-changing release: ScreenConnect 6.0. Explore all of the extras and enhancements for yourself!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Preface I don't like visual development tools that are supposed to write a program for me. Even if it is Xcode and I can use Interface Builder. Yes, it is a perfect tool and has helped me a lot, mainly, in the beginning, when my programs were small…
This is a short and sweet, but (hopefully) to the point article. There seems to be some fundamental misunderstanding about the function prototype for the "main" function in C and C++, more specifically what type this function should return. I see so…
The goal of this video is to provide viewers with basic examples to understand recursion in the C programming language.
The goal of this video is to provide viewers with basic examples to understand how to use strings and some functions related to them in the C programming language.

815 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now