Returning max 10 patients and looping over them

Returning max 10 patients and looping over them