Have this set up, how can i only take in four integers instead of all ten from the user?

Code:
#include<stdio.h>
#include<stdlib.h>

int main(void)
{
int i = 0, A[10];

printf("Input a set of up to 10 integers separated by a space to store in Array A: ");
fflush(stdout);

for(i = 0; i<10; i++)
{
    scanf("%d", &A[i]);
}
    
for(int y = 0; y<10; y++)
{
    printf("%d ", A[y]);
}

return 0;
}