[Solved] Declare two variables split by comma equals to?


It is first option

long i;
long b = get();

You would find it out faster by trying then asking on SO.

It’s called operator ,.

In this case both expressions are evaluated, but only second’s value is returned.

int x = 5;

while (--x, x > 0)
{
    printf("%d,", x);
}

has output

4,3,2,1,

This code is same as

--x;
while (x > 0)
{
    printf("%d,", x);
    --x;
}

1

solved Declare two variables split by comma equals to?