Presentation is loading. Please wait.

Presentation is loading. Please wait.

Data Structure Kartono Faqih. MATERI KULIAH Introduction to Java Class and Object Array Simple Sorting Stack and Queue Linked List Introduction to Java.

Similar presentations


Presentation on theme: "Data Structure Kartono Faqih. MATERI KULIAH Introduction to Java Class and Object Array Simple Sorting Stack and Queue Linked List Introduction to Java."— Presentation transcript:

1 Data Structure Kartono Faqih

2 MATERI KULIAH Introduction to Java Class and Object Array Simple Sorting Stack and Queue Linked List Introduction to Java Class and Object Array Simple Sorting Stack and Queue Linked List

3 MATERI KULIAH ( CONTINUED ) Recursion Advanced Sorting Trees Heaps Graph Recursion Advanced Sorting Trees Heaps Graph

4 REFERENSI Data Structures and Algorithms in Java (Mitchell Waite) Java Programming for Absolute Beginner (Lou Grinzo) Learning Java (Pat Niemeyer) FaceBook Groups : Data Structure using Java Data Structures and Algorithms in Java (Mitchell Waite) Java Programming for Absolute Beginner (Lou Grinzo) Learning Java (Pat Niemeyer) FaceBook Groups : Data Structure using Java

5 METODE KULIAH Ceramah Diskusi Tugas Mandiri Presentasi Ceramah Diskusi Tugas Mandiri Presentasi

6 INTRODUCTION TO JAVA Java Editor : NetBeans IDE 6.8 Download : Java Editor : NetBeans IDE 6.8 Download :

7 Object myInnova Merk : Toyota Warna : Silver Milage maju mundur display myInnova Merk : Toyota Warna : Silver Milage maju mundur display

8 Class Mobil Attribute / Data Merk Warna Milage Attribute / Data Merk Warna Milage

9 Class Mobil Methods maju(int km) mundur(int km) display() Methods maju(int km) mundur(int km) display()

10 public class MobilSimple { private String merk; private String warna; private int milage; public class MobilSimple { private String merk; private String warna; private int milage;

11 constructor public MobilSimple(String xmerk, String xwarna){ merk = xmerk; warna = xwarna; milage = 0; } public MobilSimple(String xmerk, String xwarna){ merk = xmerk; warna = xwarna; milage = 0; }

12 method maju(int) public void maju(int km){ milage = milage + km; } public void maju(int km){ milage = milage + km; }

13 method mundur(int) public void mundur(int km){ milage = milage + km; } public void mundur(int km){ milage = milage + km; }

14 method display() public void display(){ System.out.println("mobil "+merk+" warna "+ warna+" km = "+milage); } public void display(){ System.out.println("mobil "+merk+" warna "+ warna+" km = "+milage); }

15 main program MobilSimple mobilku; mobilku = new MobilSimple(“Toyota”,”Silver”); mobilku.maju(20); mobilku.mundur(10); mobilku.display(); MobilSimple mobilku; mobilku = new MobilSimple(“Toyota”,”Silver”); mobilku.maju(20); mobilku.mundur(10); mobilku.display();


Download ppt "Data Structure Kartono Faqih. MATERI KULIAH Introduction to Java Class and Object Array Simple Sorting Stack and Queue Linked List Introduction to Java."

Similar presentations


Ads by Google