I thought I understood assignment operations in C, but I'm trying to learn a bit of graphics programming and I've come across this initialisation statement which has me confused:

```
/* request auto detection */
int gdriver = DETECT, gmode, errorcode

```

I've compiled a small working program using the elements and the result seems to be a combination of assignment and declarations. The first variable on the RHS is assigned to the LHS variable, and the rest are declared (but not initialised) to the type of the LHS variable...

```
#include <stdio.h>

int main(){

    int a = 0;  // Comment out this line and things break
    int d = a, b, c;

    printf("%d %d %d %d", a, b, c, d);

    return 0;
}

```

Why would you use a line like this which seems to perform 2 unrelated actions together?