锘??xml version="1.0" encoding="utf-8" standalone="yes"?>亚洲国产高清aⅴ视频,亚洲精品在线网站,欧洲一区二区视频http://www.aygfsteel.com/lee/涓撴敞鎶鏈紝鍏沖績(jī)姘戠敓錛?/description>zh-cnFri, 20 Jun 2025 00:53:29 GMTFri, 20 Jun 2025 00:53:29 GMT60- 寮濮嬪涔?fàn)鐣岄潰缂柦E?/title>http://www.aygfsteel.com/lee/archive/2005/12/17/24311.htmlleeleeFri, 16 Dec 2005 17:17:00 GMThttp://www.aygfsteel.com/lee/archive/2005/12/17/24311.htmlhttp://www.aygfsteel.com/lee/comments/24311.htmlhttp://www.aygfsteel.com/lee/archive/2005/12/17/24311.html#Feedback0http://www.aygfsteel.com/lee/comments/commentRss/24311.htmlhttp://www.aygfsteel.com/lee/services/trackbacks/24311.htmlimport java.awt.event.*;
import java.util.*;
class wenben extends Frame implements TextListener,ActionListener{
Button butExit = null;
TextArea text1 = null; //杈撳叆鏂囦歡鍩?BR> TextArea text2 = null; //緇撴灉杈撳嚭鐨勬枃浠跺煙
public wenben(){
butExit = new Button();
add(butExit);
butExit.addActionListener(this);
setLayout(null);銆銆銆銆//璁劇疆鐣岄潰鐨勬牸寮?BR> setBounds(35,35,280,250);
butExit.setBounds(50,200,180,20);
butExit.setLabel("紱誨紑");
text1 = new TextArea(" ",10,10);
text1.setBounds(40,50,100,100);
text2 = new TextArea(" ",10,10);
text2.setBounds(150,50,100,100);
add(text1);
text1.addTextListener(this);
add(text2);
text2.setEditable(false);
text2.addTextListener(this);
setVisible(true);
}
public void actionPerformed(ActionEvent e){
System.exit(-1);
}
public void textValueChanged(TextEvent e)
{
double averge = 0; //鍧囧?BR> double result = 0; // 鍜?BR> int i = 0;
if(e.getSource()==text1)
{
String str = text1.getText();
StringTokenizer detect = new StringTokenizer(str); //stringtokenizer寰堢敤鐨勭被,瀵瑰瓧絎︾殑澶勭悊鍔熻兘寮哄ぇ
int n = detect.countTokens();
double[] dou = new double[n]; //涔熷彲鍒嗛厤涓闈?rùn)鎬佺殑鏁扮粍,榪欐牱涓嶇敤姣忔鍒嗛厤絀洪棿,浣嗘槸鏁扮粍鐨勯暱搴︾殑鍙樺寲緙哄皯鐏墊椿鎬?BR> for(i = 0;i<n; i++)
{
String temp = detect.nextToken();
dou[i]=Double.valueOf(temp).doubleValue();
result = result+dou[i];
}
text2.setText(""+result+'\n'+(result/i));
}
}
public static void main(String[] args){
wenben wb = new wenben();
}
}
]]> - 瀵逛袱涓汲tring綾誨瀷鐨勬瘮杈冿紟http://www.aygfsteel.com/lee/archive/2005/12/13/23641.htmlleeleeTue, 13 Dec 2005 05:19:00 GMThttp://www.aygfsteel.com/lee/archive/2005/12/13/23641.htmlhttp://www.aygfsteel.com/lee/comments/23641.htmlhttp://www.aygfsteel.com/lee/archive/2005/12/13/23641.html#Feedback1http://www.aygfsteel.com/lee/comments/commentRss/23641.htmlhttp://www.aygfsteel.com/lee/services/trackbacks/23641.htmlclass string{
static String str = new String("yes");
string(){}
}
public class rtyh {
public static void main(String[] args){
string strr = new string();
String st = new String("yes");
String str = new String("yes");
String str1 = "yes";
String str2 = "yes";
System.out.println(str1==str2);
System.out.println(st.equals(str));
System.out.println(st==str);
System.out.println(str.equals(strr.str));
System.out.println(str==strr.str);
}
}
緇撴灉涓恒ture
ture
銆銆銆銆ture
銆銆銆銆ture
false
鎵浠ワ紝==鐢ㄦ潵瀵瑰紩鐢ㄧ殑鍒ゆ柇,濡傛灉鏄紩鐢ㄧ殑鍚屼竴涓唴瀛樺崟鍏冨垯鐩哥瓑錛屽惁鍒欎笉鐩哥瓑錛巈quals錛堬級(jí)鐢ㄦ潵瀵瑰瓧絎︿覆鍐呭鐨勯愪竴鍒ゆ柇錛?/P>
]]>
主站蜘蛛池模板:
青岛市|
镇原县|
清流县|
思南县|
惠州市|
宝山区|
阿巴嘎旗|
岫岩|
饶阳县|
江口县|
赤水市|
炉霍县|
西乡县|
台前县|
隆昌县|
武汉市|
驻马店市|
铜陵市|
沈阳市|
乐亭县|
红河县|
砀山县|
大丰市|
晋宁县|
开化县|
图木舒克市|
琼中|
龙门县|
高清|
瑞金市|
临西县|
大埔县|
静宁县|
濮阳县|
平武县|
巴塘县|
枝江市|
尚义县|
呼和浩特市|
革吉县|
洛川县|