TP
This commit is contained in:
35
DEV2.1/TDs/Reels.java
Normal file
35
DEV2.1/TDs/Reels.java
Normal file
@@ -0,0 +1,35 @@
|
||||
import java.awt.*;
|
||||
import java.io.*;
|
||||
|
||||
public class Reels {
|
||||
public static void main(String[] args) {
|
||||
try {
|
||||
FileWriter fichier = new FileWriter("reels.txt");
|
||||
BufferedWriter flux = new BufferedWriter(fichier);
|
||||
|
||||
try {
|
||||
flux.write("12.8391319");
|
||||
flux.newLine();
|
||||
flux.write("45.72");
|
||||
flux.newLine();
|
||||
flux.write("12.283939273718317174");
|
||||
flux.newLine();
|
||||
flux.write("1.0");
|
||||
flux.newLine();
|
||||
|
||||
} catch (IOException e2 ) {
|
||||
System.out.println("Erreur d'écriture");
|
||||
}
|
||||
|
||||
try {
|
||||
flux.close();
|
||||
} catch (IOException e3) {
|
||||
|
||||
System.out.println("Erreur de femreture");
|
||||
}
|
||||
} catch (IOException e) {
|
||||
System.out.println("Erreur d'ouverture");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
Reference in New Issue
Block a user