How to convert String Array to Double Array in one line
<p>I have a string array as:</p>

<pre><code>String[] guaranteedOutput = Arrays.copyOf(values, values.length,
String[].class);
</code></pre>

<p>All the String values are numbers. The data should be converted to a <code>Double[]</code>.</p>

<p><strong>Question</strong><br>
Is there a one line solution in Java to achieve this or we need to loop and convert each value to a Double?  </p>
