int nTemp=0xe
-
int nTemp; nTemp=0xe; My aim is to put a hex value to a int varalbe "nTemp". As a result, the real value is 0 after those are executed. Can a int varable receive a value like 0xe directly?
-
int nTemp; nTemp=0xe; My aim is to put a hex value to a int varalbe "nTemp". As a result, the real value is 0 after those are executed. Can a int varable receive a value like 0xe directly?
An
int
holds a number, what base you write it in is irrelevant. These lines are all equivalent:int x = 15; // decimal
int x = 0xe; // hex
int x = 017; // octal--Mike-- Ericahist [updated Oct 26] | CP SearchBar v2.0.2 | Homepage | RightClick-Encrypt | 1ClickPicGrabber If my rhyme was a drug, I'd sell it by the gram.
-
An
int
holds a number, what base you write it in is irrelevant. These lines are all equivalent:int x = 15; // decimal
int x = 0xe; // hex
int x = 017; // octal--Mike-- Ericahist [updated Oct 26] | CP SearchBar v2.0.2 | Homepage | RightClick-Encrypt | 1ClickPicGrabber If my rhyme was a drug, I'd sell it by the gram.
Now the varable can get its right value. Maybe something is wrong with my VC6,isn't it? Thanks!