With your for loop, you're only generating 20 random integers. You check to see if those random integers are between a certain range, but it's pretty unlikely that they'll all be between 5 and 25. It should be a logical and comparision. It doesn't make sense to say if it's greater than five or less than 25 if you want numbers between 5 and 25!
Also, am I missing something or did you never assign random integers to the nodes of the array? If the nodes aren't initialized, you'd be getting memory addresses, I think.
It should look something like this, I think:
int randoms[20];
srand(42);
for(int i = 0; i < 20; i++)
{
// Random number between 5 and 25. Not entirely sure I did this correctly. Make sure I did!
// Edit: Changed + 5 to + 6 and % 19 to % 21
randoms[i] = ( (rand() % 21) + 6 );
cout << randoms[i] << " ";
}