reorganisation + hashmap

This commit is contained in:
Debucquoy
2023-04-26 11:24:13 +02:00
parent c561eda0cf
commit 454ac6e17e
37 changed files with 162 additions and 0 deletions

18
q2/algo/tp1/Cercle.java Normal file
View File

@ -0,0 +1,18 @@
public class Cercle {
public static final double PI = 3.14159265;
public static void main(String[] args) {
for (int i = 1; i <= 50; i++) {
System.out.println("pour un cercle de rayon : " + i + " Perimetre:" + perimetre(i)+ " aire:" + aire(i));
}
}
public static double perimetre(double rayon){
return 2*PI*rayon;
}
public static double aire(double rayon){
return PI*rayon*rayon;
}
}