title: Java doesn't display accent words correctly
body: <p>I have a java program that saves a text file and then outputs it contents in a dialog.
  When I run the program <strong>inside</strong> my IDE (BlueJ) the display is as follows:
  <img src="https://i.stack.imgur.com/udDwJ.png" alt="program inside BlueJ"><img src="https://i.stack.imgur.com/pr2Qr.png" alt="enter image description here"></p>
  
  <p>As you can see in the dialog the line "1º) Mónica" appears correctly.<br>
  But when I run the same program <strong>outside</strong> the IDE the "Mónica" doesn't appear right, as you can see in the picture:<br>
  <img src="https://i.stack.imgur.com/UEROa.png" alt="program outside BlueJ"></p>
  
  <p>How can I fix this to always display the right output?</p>
  
  <p>this is the code that reads the text file to a string</p>
  
  <pre><code>public String recordesString()
      {
          Premios premios = new Premios();
          File recordes = new File("recordes.txt");
          if(!recordes.exists()) {
              if(!client.isConnected())
                  openFTPSession();
              downloadRecordes(); // this downloads the recordes.txt file
          }
          Scanner s = null;
          try {
              s = new Scanner(recordes);
          } catch (Exception e) {
              e.printStackTrace();
          }
          String string = "";
          String linha = null;
          for(int i = 1; s.hasNext(); i++) {
              linha = s.nextLine();
              String palavra[] = linha.split(" ",2);
              string += i+"º) "+palavra[1] +"  "+ premios.getPremio(Integer.parseInt(palavra[0]))+"\n";
          }
          s.close();
          try {
              Files.deleteIfExists(Paths.get(ficRecordes));
          } catch (Exception e) {
              e.printStackTrace();
          }
          return string;
      }
  </code></pre>