Q:

How to know the next free position of array

In strings, we can know the last of the string thanks to "\0", but how can I know the next free position of an array. Here I put the code:
#include <stdio.h>

int main(){
    int notes[10];
    int i, usuari;

    printf("Put a number");
    scanf("%i", &usuari);

    for (i=0;i<usuari;i++){
        scanf("%i", &notes[i]);
    }
}

User will give a number (variable usuari). How can I know that the positions next to number, given by user, are free? And how can I print them?

A:

What you would usually do is to initialize your array to some value that would never be input, for example -1.  So, you can define notes like this:
int notes[10] = {-1};

Then you can check if notes[i] == -1 before you use it.  But, I'm just guessing what you mean by unused.
EDIT:
As pointed out the above only initializes the first element.  You would actually have to initialize notes like this:
int notes[10] = { -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,};

Or in a loop

