### Question:
LessSafe { public static String noCopyString(char[] chars) { if (javaLangAccess != null) { return javaLangAccess.newStringUnsafe(chars); } else { return new String(chars); } } private  LessSafe(); static String noCopyString(char[] chars);  }### Answer:
@Test public void makeString() throws Exception { char[] chars = "abcdef".toCharArray(); String unsafeString = LessSafe.noCopyString(chars); char[] expected = "0bcdef".toCharArray(); chars[0] = '0'; Assert.assertArrayEquals(expected, unsafeString.toCharArray()); }