Video randomly

Hi all.
I want to know if is it possible to create a VideoPlayer that plays videos (streaming) randomly each time the zapcode is scanned.

i.e. when the zapcode is scanned, a script randomize numbers (1 - 10), so, if the number selected is 3, the video https://myhost.com/videos/3.mp4 is played.

I hope you can help me.

Thanks.