Random sampling example