Home  >  Q&A  >  body text

java - new File(path, filename) 的path路径,是什么路径?

path为“D:temptest”时,拿不到文件,但是为“D:\temptest”时可以?
关于路径的知识可以讲详细一些

PHP中文网PHP中文网2741 days ago506

reply all(2)I'll reply

  • 大家讲道理

    大家讲道理2017-04-18 10:16:57

    is the path symbol. You can open a file and look at its path. This is how it is represented. This is specified by the operating system. If you have used linux, you will find that it uses /

    reply
    0
  • 天蓬老师

    天蓬老师2017-04-18 10:16:57

    I don’t know which version of Java you are using. In my local 1.7, the two writing methods are the same and both can get the file.

    reply
    0
  • Cancelreply