score:0

var prodotti = contesto.prodotti.where(x => x.prodottovisibile == 
                 true).orderbydescending(x => x.prodottoid)
//define random variable     
var random = new random();
int index = random.next(prodotti.count);    
//this line should return 5 random records from the list 
prodotti.orderby(x => rnd.next()).take(5); 

Related Query

More Query from same tag