1 / 12

高等程式語言實習課

高等程式語言實習課. 炸彈超人. 同步處理 Time sharing 能夠放炸彈且引爆 => 物件生成消滅 Data structure List Link list. 炸彈超人. Start. 初始化. 遊戲迴圈. 增加時間. 是否可動 ?. N. Y. 結束條件 ?. N. 接收控制. 顯示. Y. END. END. 炸彈超人. Start. 初始化. 遊戲迴圈. 增加時間. 結束條件 ?. N. 是否可動 ?. 顯示. N. Y. Y. END. 炸彈 ?. N. 接收控制. 影響. Y.

oleg-grant
Download Presentation

高等程式語言實習課

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. 高等程式語言實習課

  2. 炸彈超人 • 同步處理 • Time sharing • 能夠放炸彈且引爆=>物件生成消滅 • Data structure • List • Link list

  3. 炸彈超人 Start 初始化 遊戲迴圈 增加時間 是否可動? N Y 結束條件? N 接收控制 顯示 Y END END

  4. 炸彈超人 Start 初始化 遊戲迴圈 增加時間 結束條件? N 是否可動? 顯示 N Y Y END 炸彈? N 接收控制 影響 Y

  5. Java 安裝 • http://helldeathscythe.myweb.hinet.net/ • 常用程式 • JDK • NetBeans IDE 6.5.1 • 這是個很肥的編譯器 • 閒閒沒事幹 一天到晚幫你debug

  6. C++ to Java • Hello World • System.out.println(String);

  7. C++ to Java • 資料型態 int i = 147; long l = 8832L; double d = 3.1415; float f = 1.234F; char c = ‘a’; boolean same = false;

  8. C++ to Java • 陣列 int[] a = new int[10]; int a[] = new int[10]; int[] a; a = new int[10]; int a[10];

  9. C++ to Java • 觀察以下程式 const int num = 50;int socre[num]; for (int i = 0 ;i<num;i++) score[i] = 0; int[] score = new int[50]; for (int i = 0;i<score.lenght;i++) score[i]=0; 這個length…是什麼!?

  10. C++ to Java • 觀察以下程式 public static void main(String[] args) { int i[],j[]; i=new int[1]; j=i; i[0] = 123; j[0] = 456; System.out.println(i[0]); }

  11. C++ to Java • C/C++: int a[3][4]; • Java: int[][] a = new int[3][4];

  12. C++ to Java • 條件 if else swicth • 迴圈 do while for • 與C++相同

More Related