title: How do you read in a file from a subdirectory in Java?
body: <p>I have a Folder named Class and its two subdirectories are Lectures and Grades, and within those two subdirectories are txt files. How do I access the subdirectories (and maybe other subdirectories of the subdirectories Lectures and Grades)from the main directory - Class? I know I can use the absolute path in the code, but I would like to start from the starting folder, Class. So far, I have this as my code:</p>
  
  <pre><code>public class Test {
      public static void main(String[] args) {
          File directory = new File("/Users/Desktop/Class");
          File[] folder = directory.listFiles();
          for (File aFile : folder) {
              // Stuck here...
          }
      }
  }
  </code></pre>
  
  <p>Sorry.. I'm new to Java..</p>