ArrayList<String> list= new ArrayList<String>(); |
list.add( "a" ); |
list.add( "b" ); |
list.add( "c" ); |
list.add( "d" ); |
Collections.shuffle(list); |
|
for (String result:list) |
{ |
System. out .println(result); |
} |
沒有留言:
張貼留言