For knowing the sizes of different data types .,u can use the sizeof() operator.
____________________________________________________
Data type C C++ Java
____________________________________________________
int 2 2 4
char
1 1 2
long 4 4 8
float 4 4 8
double 8 8 16
____________________________________________________
sizes is not different for signed int and unsigned int. i.e., size is just two bytes for an int datatype but the only difference between a signed int and unsigned is the range of values for the variable.
The values we can store in an signed int is -32768 to +32767 and the values we can store in an unsigned int is 0 to + some 65000(i don't remember the exact value).This means we can store only positive values in an unsigned and we can store both positive and negative values in unsigned
int.
____________________________________________________
There is no concept of signed and unsigned in java.
I hope u got my answer right.
All the best.
Ur Friend........
K.VENU GOPAL RAO
Here's a new way to find what you're looking for - Yahoo! Answers
Send FREE SMS to your friend's mobile from Yahoo! Messenger Version 8. Get it NOW __._,_.___
To unsubscribe, send a blank message to <mailto:[EMAIL PROTECTED]>.
SPONSORED LINKS
| C and c++ | Computer programming languages | Java programming language |
| Basic programming language | Programming languages |
YAHOO! GROUPS LINKS
- Visit your group "c-prog" on the web.
- To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
- Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
__,_._,___
