by NoZebra120vClip · 3y ago · 0 comments
unsigned int x = 0;
const unsigned int max = ~x;
while (x <= max) {
calc(x++);
}
Or, #include <limits.h>
const unsigned int max = UINT_MAX; while (1) {
calc(x++);
}
which is an infinite loop, since the expression x <= max is always true