P
pozz
int x = <value>;
int y = (int)((unsigned)x);
The value of y is the same of x for any starting value and C
implementation?
unsigned int x = <value>;
unsigned int y = (unsigned)((int)x);
And in this case?
In other words, is there a risk to loose any value switching from
signed to unsigned and viceversa representation of integers?
int y = (int)((unsigned)x);
The value of y is the same of x for any starting value and C
implementation?
unsigned int x = <value>;
unsigned int y = (unsigned)((int)x);
And in this case?
In other words, is there a risk to loose any value switching from
signed to unsigned and viceversa representation of integers?