title: How to specify path to file in Java?
body: <p>how to add path to File Scanner in Java? I use Ubuntu and Intellij. I think I do everythink ok, but it still doesn't work :(</p>
  
  <p>Code:</p>
  
  <pre><code> File file = new File("/abc/file.txt");
  </code></pre>
  
  <p>Error:</p>
  
  <pre><code>java.io.FileNotFoundException: /abc/file.txt (No such file or directory)
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/OJtWs.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/OJtWs.png" alt="inte"></a></p>