java:
import java.util.Random;
int [] ocenki = new int [10];
Random rand = new Random ();
for( int i = 0; i < ocenki.length; i++){
ocenki[i] = rand.nextInt(3+1) + 1;
if (ocenki[i] <= 3) ocenki[i] = ocenki[i] + 1;
System.out.print(ocenki[i] + "\t");
}
java:
import java.util.Random;
int [] ocenki = new int [10];
Random rand = new Random ();
for( int i = 0; i < ocenki.length; i++){
ocenki[i] = rand.nextInt(3+1) + 1;
if (ocenki[i] <= 3) ocenki[i] = ocenki[i] + 1;
System.out.print(ocenki[i] + "\t");
}