i am having issues writing this code and i think i botched the whole thing can someone point me in the right direction? here is what i have so far
public class FArray {
// build an array of 10 numbers of random numbers, and then display them out
public static void main(String[] args) {
// declare an array (named numbs) that holds 10 ints
int[] numbs = new int[10];
// write a for loop that loops 10 times and generates a random number between 0 and 100
for (int i = 0; i < numbs.length; i++) {
numbs[i] = (int) (Math.random() * 100 + 1);
// assign the random number to each element in the array , numbs
numbs = new numbers();
// write a for loop that displays to the screen each random number in the array named numbs
numbers[i] = Numbers;
}
}
}
Aucun commentaire:
Enregistrer un commentaire