Read a file character by character/UTF8: Difference between revisions
Read a file character by character/UTF8 (view source)
Revision as of 00:54, 26 May 2023
, 1 year ago→Using Java 11
Line 400:
<syntaxhighlight>
import java.io.
import java.io.IOException;
import java.nio.charset.StandardCharsets;
import java.nio.file.Files;
import java.nio.file.Path;
public final class ReadFileByCharacter {
public static void main(String[] aArgs) {
try (
int value;
while ( ( value =
System.out.println((char) value);
}
|