unsigned-integer Questions
3
Solved
I have a byte[4] which contains a 32-bit unsigned integer (in big endian order) and I need to convert it to long (as int can't hold an unsigned number).
Also, how do I do it vice-versa (i.e. from ...
Inefficacious asked 24/3, 2012 at 20:1
3
Solved
What will the unsigned int contain when I overflow it? To be specific, I want to do a multiplication with two unsigned ints: what will be in the unsigned int after the multiplication is finished?
...
Ariellearies asked 8/2, 2012 at 13:6
4
Solved
I am trying to write a function in C++ which takes two 64 bit unsigned integers and returns their difference in a signed 64 bit integer. It seems to be a bit complicated because of the overflow sit...
Fanatical asked 16/1, 2012 at 20:43
7
Solved
Lets assume we are talking about 32bit system.
PHP doesn't support unsigned INT. It means that INT value should be between -2,147,483,648 and 2,147,483,647 values. And INT takes 4 bytes to store a...
Seabolt asked 7/1, 2012 at 16:5
4
Solved
When I try to compile the following C++ program using the Visual Studio 2010 C++ compiler (X86) with warning level /W4 enabled, I get a signed/unsigned mismatch warning at the marked line.
#includ...
Hosanna asked 19/12, 2011 at 19:6
3
Solved
How do I convert an unsigned int to jint? Do I have to convert it at all, or can I just return it without any special treatment? This is basically my code right now, but I can't test it, as I haven...
Tonguelashing asked 4/11, 2011 at 16:20
4
Solved
Wow I thought I knew my C++ but this is weird
This function returns an unsigned int so I thought that means I will never get a negative number returned right?
The function determines how many hou...
Markham asked 1/10, 2011 at 4:10
2
Solved
I want to reinterpret an unsigned long (actually, a DWORD) as a signed long. I tried:
DWORD x;
long y = reinterpret_cast<signed long>(x);
However, VC++2010 intellisense tells me "Invalid t...
Trickish asked 15/7, 2011 at 15:22
3
Solved
In limits.h, there are #defines for INT_MAX and INT_MIN (and SHRT_* and LONG_* and so on), but only UINT_MAX.
Should I define UINT_MIN myself? Is 0 (positive zero) a portable value?
Shook asked 17/8, 2010 at 4:24
3
Solved
What is the difference between using int and uint? All the examples I have seen so far are using int for integers. Any advantage of using uint? Thanks.
Hydrargyrum asked 18/6, 2010 at 9:21
© 2022 - 2024 — McMap. All rights reserved.