Не проходит и я не понимаю почему. Прошу помочь!
package com.javarush.task.task32.task3210;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.RandomAccessFile;
import java.nio.charset.StandardCharsets;
/*
Используем RandomAccessFile
*/
public class Solution {
public static void main(String... args) throws IOException {
String fileName = args[0];
int number = Integer.parseInt(args[1]);
String text = args[2];
RandomAccessFile raf = new RandomAccessFile(fileName, "rw");
raf.seek(number);
byte[] bytes = fileName.getBytes();
int textFormFile = raf.read(bytes, 0, text.length());
String s = new String(bytes, StandardCharsets.UTF_8);
raf.seek(raf.length());
if (s.equals(text)){
raf.write("true".getBytes());
} else raf.write("false".getBytes());
}
}