I wrote a little pointer program and I just have an error that I don't get.
is supposed to make numSize 6 when:Code:numSize = ceil( (float) (max - min) / interval ) + 1;
But I get numSize = 1026Code:int min = 0 int max = 10 int interval = 2
seems to work fine like this:
the reason I need the ceil in there is because ifCode:numSize = ((max - min) / interval ) + 1;
I need 5 and not four.Code:int min = 0 int max = 10 int interval = 3
I am using visual C++ to compile and debug (I tried cygwin but vista does not ply nice).
Is the problem specific to VC++?