how to clear integer array

C

Christophe Vanfleteren

Junior said:
hi,


i am new with java and i kinda lost how to clear array in integer.

thanks

jerry

Please do not multi post. You've gotten an answer in comp.lang.java.help.
 
M

Michael Borgwardt

Junior said:
i am new with java and i kinda lost how to clear array in integer.

java.util.Arrays.fill()

But remember that in java, freshly instantiated arrays are always
initialized with the default value (0 in the case of int) - the
spec requires it.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,045
Latest member
DRCM

Latest Threads

Top