int main(void)
{
unsigned int y = 10;
int x = – 4;
if (x > y)
Printf("x is greater");
else
Printf("y is greater");
getch();
return (0);
}
Output: x is greater
Run Code Online (Sandbox Code Playgroud)
我认为输出y会更大,因为它是无符号的.这背后的原因是什么?