JAVA lb-4 fixes
This commit is contained in:
Binary file not shown.
Before Width: | Height: | Size: 24 KiB |
Binary file not shown.
Before Width: | Height: | Size: 69 KiB |
Binary file not shown.
Before Width: | Height: | Size: 23 KiB |
Binary file not shown.
Before Width: | Height: | Size: 33 KiB |
@ -34,7 +34,9 @@ public class Part1 {
|
||||
|
||||
if (input.equalsIgnoreCase("stop")) {
|
||||
break;
|
||||
} else if (input.equals("Latn")) {
|
||||
}
|
||||
|
||||
if (input.equals("Latn")) {
|
||||
result = extractWords(fileContent, LATN_PATTERN);
|
||||
} else if (input.equals("Cyrl")) {
|
||||
result = extractWords(fileContent, CYRL_PATTERN);
|
||||
|
@ -14,11 +14,13 @@ public class Part2 {
|
||||
|
||||
InputStream stdin = System.in;
|
||||
|
||||
System.setIn(new ByteArrayInputStream(symin.getBytes(StandardCharsets.UTF_8)));
|
||||
try {
|
||||
System.setIn(new ByteArrayInputStream(symin.getBytes(StandardCharsets.UTF_8)));
|
||||
WordContainer.main(args);
|
||||
} finally {
|
||||
System.setIn(stdin);
|
||||
}
|
||||
|
||||
WordContainer.main(args);
|
||||
|
||||
System.setIn(stdin);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -25,6 +25,5 @@ public class Part3 {
|
||||
ResourceBundle bundle = ResourceBundle.getBundle(BASE_NAME, locale);
|
||||
System.out.println(bundle.getString(parts[0]));
|
||||
}
|
||||
scanner.close();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user