SyntaxFix
Write A Post
Hire A Developer
Questions
It mostly depends on how big n is.
n
If n==0, nothing beats option#1 :)
n==0
If n is very large, toArray(new String[n]) is faster.
toArray(new String[n])