Use %u instead of %d for unsigned int variables.