How to create a String array?

I forgot the syntax and I cannot find it in the API.

Pls help.

[75 byte] By [leolee1022a] at [2007-11-27 10:40:44]
# 1

Go on then, although really it would be quicker for you to google "java array"

String[] stringArray = new String[10];

You could also use this, in some circumstances

String[] stringArray = { "this, "is", "a", "string", "array" };

georgemca at 2007-7-28 19:08:30 > top of Java-index,Java Essentials,Java Programming...
# 2

String[] array = new String[5];

Maybe?

Edit: To slow, incomplete, and sarcastic. ;-)

masijade.a at 2007-7-28 19:08:30 > top of Java-index,Java Essentials,Java Programming...
# 3

thanks all.

leolee1022a at 2007-7-28 19:08:30 > top of Java-index,Java Essentials,Java Programming...
# 4

You can't be too sarcastic.

paulcwa at 2007-7-28 19:08:30 > top of Java-index,Java Essentials,Java Programming...
# 5

> You can't be too sarcastic.

Really? How incredibly interesting......

georgemca at 2007-7-28 19:08:30 > top of Java-index,Java Essentials,Java Programming...
# 6

> > You can't be too sarcastic.

>

> Really? How incredibly interesting......

now that you mention it...

jwentinga at 2007-7-28 19:08:30 > top of Java-index,Java Essentials,Java Programming...
# 7

> > > You can't be too sarcastic.

> >

> > Really? How incredibly interesting......

>

> now that you mention it...

Don't be so racist :-)

georgemca at 2007-7-28 19:08:30 > top of Java-index,Java Essentials,Java Programming...
# 8

I don't want play this word game. I take me toys and go home now. WHAAAAAAAAAAH!!!!!!! (There my yamm impersonation of the day) ;-)

masijade.a at 2007-7-28 19:08:30 > top of Java-index,Java Essentials,Java Programming...
# 9

> Go on then, although really it would be quicker for

> you to google "java array"

>

> > String[] stringArray = new String[10];

>

>

> You could also use this, in some circumstances

>

> > String[] stringArray = { "this, "is", "a", "string",

> "array" };

>

I just noticed, did you forget something on "this"? ;-)

masijade.a at 2007-7-28 19:08:30 > top of Java-index,Java Essentials,Java Programming...
# 10

Ah. You spotted my deliberate mistake designed to see if you were paying attention</lie>

georgemca at 2007-7-28 19:08:30 > top of Java-index,Java Essentials,Java Programming...