Update all new Tasks
This commit is contained in:
parent
00a190b0a6
commit
91df62d461
5697 changed files with 93386 additions and 804 deletions
9
Task/File-input-output/Java/file-input-output-5.java
Normal file
9
Task/File-input-output/Java/file-input-output-5.java
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
import java.nio.file.*;
|
||||
public class Copy{
|
||||
public static void main(String[] args) throws Exception{
|
||||
FileSystem fs = FileSystems.getDefault();
|
||||
Path in = fs.getPath("input.txt");
|
||||
Path out = fs.getPath("output.txt");
|
||||
Files.copy(in, out, StandardCopyOption.REPLACE_EXISTING);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue