Y = ceil(6*rand(1,n)); Z = ceil(6*rand(1,n)); X = Y + Z;