Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package unit_07;
- import java.util.Random;
- public class StartApp {
- public static void main(String[] args) {
- // TODO Auto-generated method stub
- Random r = new Random();
- GeometrischeFigur[] gf = new GeometrischeFigur[10];
- for(int i=0; i<10;i++){
- int zahl = r.nextInt() % 2;
- if(zahl==0){
- gf[0] = new Dreieck();
- } else{
- }
- }
- for(int i=0; i<10; i++){
- gf[i].zeichne();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement