import java.awt.Point; public class point { public static void main(String[] args) { Point[] tab =new Point[10]; int x; int y; for (int i = 0;i<10;i++) { x = (int)(Math.random()*200)-100; y = (int)(Math.random()*200)-100; tab[i] = new Point(x,y); } for (int i = 0;i<10;i++) { for (int j = 0;j<10;j++) { System.out.println("la distance entre le point "+ i+"et le point"+j+"est de:"+tab[i].distance(tab[j])); } System.out.println(); } } }