Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Point [][] p = new Point[10][2];
- for (int i = 0; i < p.length;i++){
- Point c = new Point((int)(Math.random() * ((10 - 0) + 1)) + 0, //Random points
- (int)(Math.random() * ((10 - 0) + 1)) + 0);
- p[i][1] = c;
- }
- System.out.println(p[2][1]);
- for(int row=0; row < p.length;row++){
- for (int column = 0; column < p[row].length;column++) {
- System.out.print(p[row][column] + " ");
- }
- System.out.println();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement