I need to finish a program that will create an array of 10 random numbers from 1-100 and print them out in order then print them out in reverse order, can anyone help me? this is where I'm currently at.
int main()
{
int arr[10];
srand(0);
int i, n;
for(i=0;i<100;i++)
{
arr[i] = rand();
printf(" %d", i );
}
return 0;
}
Aucun commentaire:
Enregistrer un commentaire