Підкажіть, що не так?
package ua.javarush.task.pro.task15.task1517;
import java.io.IOException;
import java.nio.file.Files;
import java.nio.file.Path;
import java.util.Scanner;
/*
Файлові операції
*/
public class Solution {
public static void main(String[] args) throws IOException {
Scanner scanner = new Scanner(System.in);
Path filePath = Path.of(scanner.nextLine());
Path fileNewPath = Path.of(scanner.nextLine());
//напишіть тут ваш код
if (!Files.exists(filePath)) {
Files.createFile(filePath);
}
if (!Files.exists(fileNewPath)) {
Files.move(filePath, fileNewPath);
}else {
Files.delete(filePath);
}
}
}