Go4Expert (http://www.go4expert.com/)
-   C (http://www.go4expert.com/forums/c/)
-   -   Data Types Teasing Me (http://www.go4expert.com/forums/data-types-teasing-t10863/)

usama_muneeb 28May2008 12:05

Data Types Teasing Me
Hi all,
I am just a beginner in C and the most terrible chapter is understanding Data Types. The discussion is all blunder to me. One thing I don't understand, why this constant is so used in int variables:


when an x is coming in the way, but integers are numeral values in maths. Also do tell me if its a constant or a variable name. I am bitterly confused.

atul.sharma12 29May2008 16:39

Re: Data Types Teasing Me
Dear Muneeb,

Numbers can be represent in many ways like:


The number you mentioned is in the Hexadecimal form and if the mentioned number is withing the range of the integer data type then it can be used as int.Better you clear your concepts in data representation systems this will help you a lot.

usama_muneeb 29May2008 21:45

Re: Data Types Teasing Me
But the number you are talking about can only be tested for its range using some for loop. I have the LPE Programming in C textbook (Stephen G. Kochan) but I haven't the slightest clue on the use of this int.

As far as I remember, hexadecimal is like this in HTML: #FF00FF. What type of hexadecimal is it?

All times are GMT +5.5. The time now is 09:11.