#include <stdio.h>
int main(void)
{
int array[] = { [3] = 89, [5] = 34, [12] = 897, [15] = 6, [17] = 1987 };
for (int i = 0; i <= 17; i++)
printf("array[%d] = %d\n", i, array[i]);
return 0;
}
/*
run:
array[0] = 0
array[1] = 0
array[2] = 0
array[3] = 89
array[4] = 0
array[5] = 34
array[6] = 0
array[7] = 0
array[8] = 0
array[9] = 0
array[10] = 0
array[11] = 0
array[12] = 897
array[13] = 0
array[14] = 0
array[15] = 6
array[16] = 0
array[17] = 1987
*/