JavaÖظ´Ï´ÅÆ
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
import java.util.Random;
public class ShuffleTest {
public static void main(String args[]) {
String simpsons[] = { "Bart", "Hugo", "Lisa", "Marge", "Homer",
"Maggie", "Roy" };
List list1 = Arrays.asList(simpsons);
List list2 = Arrays.asList(simpsons);
Random rand = new Random(100);
Collections.shuffle(list1, rand);
Collections.shuffle(list2, rand);
System.out.println(list1);
System.out.println(list2);
}
}
Ïà¹ØÎĵµ£º
JavaÖеļòµ¥¹¤³§Ä£Ê½
¾ÙÁ½¸öÀý×ÓÒÔ¿ìËÙÃ÷°×JavaÖеļòµ¥¹¤³§Ä£Ê½£º
Å®æ´ÞÒÍÁÔìÈË
»°Ëµ£º“ÌìµØ¿ª±Ù£¬Î´ÓÐÈËÃñ£¬Å®æ´ÞÒÍÁΪÈË¡£”Å®æ´ÐèÒªÓÃÍÁÔì³öÒ»¸ö¸öµÄÈË£¬µ«ÔÚÅ®æ´Ôì³öÈË֮ǰ£¬È˵ĸÅÄîÖ»´æÔÚÓÚŮ洵Ä˼ÏëÀïÃæ¡£
Å®æ´ÔìÈË£¬Õâ¾ÍÊǼòµ¥¹¤³§Ä£Ê½µÄÓ¦Óá£
¡¡¡¡Ê×ÏÈ£ ......
WindowsÏÂJAVAÓõ½µÄ»·¾³±äÁ¿Ö÷ÒªÓÐ3¸ö£¬JAVA_HOME¡¢CLASSPATH¡¢PATH¡£ÏÂÃæÖð¸ö·ÖÎö¡£
JAVA_HOMEÖ¸ÏòµÄÊÇJDKµÄ°²×°Â·¾¶£¬Èçx:\JDK_1.4.2£¬ÔÚÕâ·¾¶ÏÂÄãÓ¦¸ÃÄܹ»ÕÒµ½bin¡¢libµÈĿ¼¡£ÖµµÃÒ»ÌáµÄÊÇ£¬JDKµÄ°²×°Â·¾¶¿ÉÒÔÑ¡ÔñÈÎÒâ´ÅÅÌĿ¼£¬²»¹ý½¨ÒéÄã·ÅµÄĿ¼²ã´Îdzһµã£¬Èç¹ûÄã·ÅµÄĿ¼ºÜÉ±ÈÈçx:\XXXXXX\xxxxx\XXXX\xxxx ......
¼ÆËãÒ»ÏÂʱ¼ä£¡ÎÒ¿ªÊ¼Ñ§Ï°JAVA±à³ÌÒѾÁ½¸öÔÂÁË£¬Ã¿½Ú¿Î¶¼ÊÇÔÚѧϰһÏÂÀíÂ۵Ķ«Î÷¡£¸Ð¾õÉÏûɶÓô¦Ò»Ñù£¬ËùÒÔ×Ô¼º×ÅÊÖ×öһЩ¼òµ¥µÄJAVA±à³Ì¡£µÚÒ»´Î±à³Ì¿Ï¶¨Ã»·¨¸ú´óʦÃDZȽÏÁË£¬µ«ÊÇÕâÒ²¼ûÖ¤ÁËÎÒŬÁ¦µÄ½á¹û£¡
import java.awt.*;
import java.awt.event.*;
import java.util.Date;
import javax.swing.JPassword ......
WindowsÏÂJAVAÓõ½µÄ»·¾³±äÁ¿Ö÷ÒªÓÐ3¸ö£¬JAVA_HOME¡¢CLASSPATH¡¢PATH¡£ÏÂÃæÖð¸ö·ÖÎö¡£ JAVA_HOMEÖ¸ÏòµÄÊÇJDKµÄ°²×°Â·¾¶£¬Èçx:\JDK_1.4.2£¬ÔÚÕâ·¾¶ÏÂÄãÓ¦¸ÃÄܹ»ÕÒµ½bin¡¢libµÈĿ¼¡£ÖµµÃÒ»ÌáµÄÊÇ£¬JDKµÄ°²×°Â·¾¶¿ÉÒÔÑ¡ÔñÈÎÒâ´ÅÅÌĿ¼£¬²»¹ý½¨ÒéÄã·ÅµÄĿ¼²ã´Îdzһµã£¬Èç¹ûÄã·ÅµÄĿ¼ºÜÉ±ÈÈçx:\XXXXXX\xxxxx\XXXX\xxxx\X ......
1.ÒýÑÔ
Java I/OϵͳÊǽ¨Á¢ÔÚÊý¾ÝÁ÷¸ÅÄîÖ®Éϵģ¬¶øÔÚUNIX/LinuxÖÐÓÐÒ»¸öÀàËƵĸÅÄ¾ÍÊǹܵÀ£¬Ëü¾ßÓн«Ò»¸ö³ÌÐòµÄÊä³öµ±×÷ÁíÒ»¸ö³ÌÐòµÄÊäÈëµÄÄÜÁ¦¡£ÔÚJavaÖУ¬¿ÉÒÔʹÓùܵÀÁ÷½øÐÐÏß³ÌÖ®¼äµÄͨÐÅ£¬ÊäÈëÁ÷ºÍÊä³öÁ÷±ØÐëÏàÁ¬½Ó£¬ÕâÑùµÄͨÐÅÓбðÓÚÒ»°ãµÄShared DataͨÐÅ£¬Æä²»ÐèÒªÒ»¸ö¹²ÏíµÄÊý¾Ý¿Õ¼ä¡£
2.Ïà¹ØÀ༰Æä¹Øϵ
1£© ......