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

正文內(nèi)容

java實(shí)例-按學(xué)號(hào)順序打印某門(mén)課程學(xué)生的成績(jī),并統(tǒng)計(jì)平均成績(jī)-資料下載頁(yè)

2025-01-12 08:21本頁(yè)面
  

【正文】 else{ 19. stuNumber=。 20. } 21. s=new Student[stuNumber]。 22. =new int[stuNumber][2]。 23. for(int i=0。istuNumber。i++){ 24. stu[i]=s[i]。 25. [i]=score[i]。 26. } 27. } 28. } 課程成績(jī)類(lèi) CourseScore 23. //獲得所有學(xué)生的成績(jī) 24. public int[][] getAllScore(){ 25. return score。 26. } 27. //查詢某個(gè)學(xué)生的成績(jī) 28. public int getScore(int stuID){ 29. for(int i=0。i。i++){ 30. if(stu[i].num==stuID){ 31. return score[i][1]。 32. } 33. } 34. return 0。 35. } 36. public float getAvgScore(){ 37. float avgScore=。 38. for(int i=0。i。i++){ 39. avgScore+=score[i][1]。 40. } 41. return avgScore/。 42. } 43. } 統(tǒng)計(jì)成績(jī)類(lèi) TJ_Score 1. public class TJ_Score { 2. public static void main(String[] args) { 3. CourseScore cs=new CourseScore(java)。 4. Student s1 = new Student(1,18,張三 )。 5. Student s2 = new Student(2,21,小路 )。 6. Student s3 = new Student(3,20,John)。 7. Student s4 = new Student(4,20,Lucy)。 8. Student s5 = new Student(5,17,Jack)。 9. Student s[] = {s1,s2,s3,s4,s5}。 10. int score[][]={{1,70},{2,78},{3,60},{4,90},{5,85}}。 11. (s, score)。 12. for(int i=0。i。i++){ 13. (s[i].num+ +s[i].name+ +(s[i].num))。 14. } 15. (平均成績(jī): +())。 16. } 17. } 作業(yè) 4:查詢圖書(shū)信息 ? 根據(jù)條件查詢圖書(shū)的信息,并打印 Questions?
點(diǎn)擊復(fù)制文檔內(nèi)容
教學(xué)課件相關(guān)推薦
文庫(kù)吧 www.dybbs8.com
備案圖鄂ICP備17016276號(hào)-1