Return a random object from the stream
$75
top 5
30
submissions
DONE
46 months ago
Default challenge

Suppose you have a stream object. This stream object ONLY has two methods. They are:

HasNext() - returns a boolean if there are more items in the stream

GetNext() - returns the next item in the stream

Given a stream such as this one, return a random object from it. No, the stream cannot be reset.

Deliverables
Leaderboard
Top 5 share $75
$15.00 Square pic 60 hoa3 University of California at San Diego
$15.00 T University of Michigan
$15.00 R Rochester Institute of Technology
$15.00 Square pic 60 a17f956af0cc98ef09029fe181a1d598 Wesleyan University
$15.00 Square pic 60 befunky underpainting 1 University of Toronto
Want to stay up to date with new challenges? Follow us on Instagram under @mindsumo!