I am printing out values in a for loop

for(i = 0; i<value[0]; i++)
{
fprintf(output,"%f\n",value[0]);
fclose(output);

}
this prints data only in one column.

but i want to print out only 10 at a time and then "\n",
and print 10 more and so on. How would I go about doing this?

Thankx.