π CSV Parsing
βͺ code
BufferedReader file = new BufferedReader(
new FileReader("csv νμΌ μμΉ\\csv νμΌ μ΄λ¦"));
String line = "";
try {
Set<String> set = new HashSet<>();
while ((line = file.readLine()) != null) {
List<String> aLine = new ArrayList<>();
String[] arr = line.split(",");
for (String s : arr) {
System.out.println(s);
}
}
} catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
} finally {
try {
if (file != null) {
file.close();
}
} catch (IOException e) {
e.printStackTrace();
}
}