I am hesitant to post my code because this is for a school assignment, but basically I need to iterate through a uint64_t
that can be very large.
So, I have a value that is basically going to be maybe 10 characters long. It originally was an int
, and the code partially works (but doesn't finish creating the output it's supposed to) but then I'd get the error "warning: integer constant is so large that it is unsigned"
.
I'd then change that int
to uint64_t
(it's being multiplied by 10), and it would give me a floating point exception.
Any insight without the code?
EDIT: Adding little bits of code...
uint64_t number = 1U;
...
for (int x = 0; x < y; x++) {
number *= 10;
}
^ this gives me the floating point exception.
Not sure if this is enough to be helpful.