@Test
public void testOptional() {
String strArr[] = {"sada", null, ""};
for (String s : strArr) {
System.out.println(Optional.ofNullable(s).orElse("").length());
}
}
@Test
public void testOptional() {
String strArr[] = {"sada", null, ""};
for (String s : strArr) {
System.out.println(Optional.ofNullable(s).orElse("").length());
}
}