Hallo, ich bin ein blutiger Anfänger und ich bitte um Verständnis.
Meine Programmierung sieht so aus:
Code (Java):
public class randomarray
{
public static void main
(String []args
) {
int wert
= 0;
int [] a
= new int [10];
for(int i
=0; i
<10; i
++) {
a
[i
]= (int)Math.
random();
System.
out.
print(a
[i
]);
}
}
}
Der Ausgabewert ist 10x die 0... Wo liegen die Fehler?
Array mit Zufallszahlen - Anfänger - Hilfe
0 commentaires:
Enregistrer un commentaire