code: public static String readFile( String name ) throws IOException {
          StringBuilder b = new StringBuilder();
          BufferedReader r = new BufferedReader(new FileReader(name));
          String line;
          while( (line = r.readLine()) != null ) {
              b.append(line).append('\n');
          }
          r.close();
          return b.toString();
      }
docs: Read a file and provide its content as String.
  
  @param name the file name
  @return the content as String
  @throws IOException something bad happened.