unsigned long nBolum = 0L;
unsigned long nKalan = 0L;
unsigned long ulA = 0L;
unsigned long ulB = 0L;
...
printf("ulA=%u\n",ulA);
printf("ulB=%u\n",ulB);
nBolum = (unsigned long) ulA/ulB;
nKalan = (unsigned long) ulA%ulB;
printf("nBolum = %u\n",nBolum);
printf("nKalan = %u\n",nKalan);
printf("HVFE.c exiting\n");
exit(1);
it prints :
ulA=2607503366
ulB=16777215
nBolum = 65435
nKalan = 7100321
to the screen.
but nBolum must be 155.419.... Why is this happenning?
thanx.