import java.io.File; public class Main { public static void main(String[] args) { File[] rootDirectories = File.listRoots(); System.out.println("Available root directories:"); for (int i = 0; i < rootDirectories.length; i++) { System.out.println(rootDirectories[i]); } } }