freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內容

java實驗報告-預覽頁

2024-11-05 06:07 上一頁面

下一頁面
 

【正文】 ileName = ”無標題“。js = new JScrollPane(textArea)。()。//文本區(qū)域添加右鍵 (popupMenu)。setBackground()。(edit)。for(int i=0。//注冊各個菜單項的事件監(jiān)聽器for(int i=0。fileName = ()+()。if(fileName!=null){ writeFile(fileName)。StringSelection selection= new StringSelection(text)。(selection,null)。String text。} else if(eventSource == menuItem[8])//自動換行 { if(())(false)。//設置字體 }else if(eventSource == menuItem[11])//幫助 { try { String filePath = ”C:/WINDOWS/Help/“。(null, help, ”關于記事本“, , )。} catch(PrinterException e1){ ()。int charsRead = 0。(new String(content,0,charsRead))。(())。Container con = ()。final JTextField findText = new JTextField(30)。final JRadioButton up = new JRadioButton(”向上(U)“)。(down)。//”替換“按鈕的事件處理(new ActionListener(){ public void actionPerformed(ActionEvent e){ if(().length()== 0 amp。amp。//將光標放到編輯區(qū)開頭 int a = 0, b = 0, replaceCount = 0。} while(a 1){ int FindStartPos = ()。str3 = ()。} else { strA = str2。} else { a = (strB, ().length()+ 1)。} else if(()){(a)。} else { (findDialog, ”成功替換“+ replaceCount + ”個匹配內容!“, ”替換成功“,)。replaceCount++。replaceCount++。String str1, str2, str3, str4, strA, strB。str4 = ()。strB = str4。(a, a + b)。} } else { (null, ”找不到您查找的內容!“, ”記事本“, )。} })。JPanel direction = new JPanel()。JPanel replacePanel = new JPanel()。(replaceAll)。(replaceContentLabel)。(direction)。(bottomPanel)。(true)。JLabel searchContentLabel = new JLabel(” 查找內容(N):“)。final JRadioButton up = new JRadioButton(”向上(U)“)。(down)。String str1, str2, str3, str4, strA, strB。str4 = ()。strB = str4。(a, a + b)。} } else { (null, ”找不到您查找的內容!“, ”記事本“, )。} })。JPanel direction = new JPanel()。(searchContentLabel)。(direction)。(bottomPanel)。(true)。import 。import 。import .*。private int width = 480。private int size = 12。private JLabel lbl1 = new JLabel(”字體:“)。String[] zx = { ”常規(guī)“, ”加粗“, ”斜體“, ”基線“ }。private String[] zt。(new FlowLayout())。(lbl2)。(okButton)。(true)。(new ItemListener(){ // public void itemStateChanged(ItemEvent event){ //獲取選擇用戶的字體類型name =(String)()。if((”常規(guī)“)){ type = 。} else if((”斜體“)){ type = 。} } })。}public Font showFontDialog(){ (true)。cancelButton = new JButton(”取消“)。(6)。(true)。}public void setWidth(int width){ = width。}private void setCustomFont(Font customFont)//{ = customFont。}設置字體 public Font getCustomFont()//獲取字體 { return()。} else if(()== okButton){ okpressed = true。實驗報告書寫說明實驗報告中實驗目的和要求、實驗儀器和設備、實驗內容與過程、實驗結果與分析這四項內容為必需項。(3)盡量采用專用術語來說明事物。實驗報告的批改成績采用五級記分制或百分制,按《金陵科技學院課堂教學實施細則》中作業(yè)批閱成績評定要求執(zhí)行。public class Hello { public static void main(String args[]){ (“Hello!”)。import .*。}} (3)根據(jù)變量score中存放的考試分數(shù),輸出對應的等級。①n=4 0 0 0 0 0 1 1 1 0 1 2 2 0 1 2 3 ② n=4 1 1 2 1 1 2 3 2 1 1 2 3 4 3 2 1(6)求二維數(shù)組的鞍點,即該位置上的元素在該行上最大,在列上最小。String s2 = “This is the second string.”。boolean result121 = (s2)。boolean result141 = (s4)。(“s1 equals s2= ” +result121)。(“s1 equals s4= ” +result141)。} }(8)判斷回文字符串回文是一種“從前向后讀”和“從后向前讀”都相同的字符串。(9)使用String類的pareTo(String s)方法,對以下字符串從小到大排序:“melon”, “apple”, “pear”, “banana”,顯示輸出排序結果。} public static void main(String args[]){new Hello()。public void init(){=100。} }(3)package b。(“請輸入分數(shù)按回車”)。amp。score(“B”)。}else if(score(“D”)。i 。(prime[i] + “ ”)。for(int i = start。step++。for(i=0。j=i。i=j。j(arr[i][j])。for(int i=0。}int k=i+1。num[i][j]=k。for(int i=0。}boolean find = false。amp。boolean yes = true。 j{if(mat[j][max]yes=false。}if(find)(“The dort: ”+mat[row][max])。SuppressWarnings(“resource”)Scanner input = new Scanner()。//將Sr倒置的方法 String newStr=new String(sb)。public class SortString { public static void main(String[] args){// TODO Autogenerated method stubString [ ] a={“melon”,“apple”,“pear”,“banana”}。(“排序結果是:”)。(b)。在實驗中,配置jdk的環(huán)境變量要注意它的path和 classpath,如果classpath本身就有,可以在后面加分號,這樣不影響其它的classpath的使用。三、實驗過程(1)定義一個Man類,類中包含說話方法如下: public class Man{public void say(){(“我是中國人!”);}} ;,其中定義China類如下: public class China{public static void main(String[] args){Man lihua = new Man()。(3)包的建立與使用:設計計算器類Calculator,計算加、減、乘、除和立方體體積,并且打包為mypackage。編寫銀行帳戶類BankAccount,包含數(shù)據(jù)成員:余額(balance)、利率(interest);操作方法:查詢余額、存款、取款、查詢利率、設置利率。2)設計一個描述本科生的類Undergraduate,該類繼承并擴展Student類。(7)試編碼實現(xiàn)多態(tài)在工資系統(tǒng)中的應用:給出一個根據(jù)雇員類型利用abstract方法和多態(tài)性完成工資單計算的程序。提示:對所有雇員類型都使用earnings()方法,但每個人掙的工資按他所屬的雇員類計算,所有雇員類都是從超類Employee派生出的。程序依次使用數(shù)組的每個元素(Employee引用)調用每個對象的earnings()方法。lastName=last。} public abstract String earnings()。定義一個測試類,測試飛機和鳥。使用三個catch子句,分別捕捉輸入輸出異常、除數(shù)為0的異常和參數(shù)輸入有誤異常。String cl=()。int b=(cl)。(11)編寫程序包含自定義異常MyException,當100被13和4除時拋出該異常,其余除數(shù)顯示商值。// public class Man { public void say(){(”我是中國人!“)。//主方法先創(chuàng)建類然后調用類()。} public Complex(double real){this(real,0)。} public void setReal(double real){ = real。return C。return C。amp。==)。Complex c3=new Complex()。} }(3)public class Calculate { double i,j, t。=j。} public double cheng(){return i*j。Calculate c2=new Calculate(8,4,2)。(”相除 =“+())。=cunkuan。(”余額為:“+balance)。(40000,20000)。} }(5)public class Student { String name。public Student(String name,int age){=name。} public float get(){return average。else (”本科生成績不合格“)。else (”研究生成績不合格“)。(”本科生平均分=“+())。(”研究生生三門成績分別為“+”90,“+”84,“+”88“)。}(6)public abstract class ClosedFigure {//定義抽象類String shape。} public class Triangle extends ClosedFigure {// ClosedFigure繼承Triangle double a,b,c。=c。return (s*(sa)*(sb)*(sc))。()。public Employee(String first,String last){firstName=first。} public String toString(){return firstName+lastName。 = salary。double price。 = price。public PieceWorker(String first, String last, double number,double price){super(first, last)。}} public final class HourlyWorker extends Employee {double time。 = money。Employee c2=new CommissionWorker(”李“,”四“,4000,1500,2)。Employee c4=new HourlyWorker(”劉“,”三“,600,30)。double height。=r。} public class Yuanzhu extends Circle implements Volume { public Yuanzhu(String shape, double r, double height, double pi){ super(shape, r, height, pi)。// TODO Autogenerated constructor stub } double s。} } public class Test { public static void main(String[] args){Yuanzhu c1=new Yuanzhu(”圓柱“,4,6,)。(”圓錐表面積:“+())。}
點擊復制文檔內容
醫(yī)療健康相關推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號-1