Mis-conceptions about the Java<br />Presenter: Engineer Jokhio Salahuddin Kohistani 07CS24<br />Object Oriented Programmin...
Contents<br /><ul><li>My First Java Program
Static and Non-Static
Objects
Interfaces
Wrapper Classes</li></li></ul><li>My First Java Program<br />class MyClass{<br />	public static void main(String[ ] args){...
Static & Non-Static<br />class MyClass2{<br />int me=6;<br />	public static void main(String [ ] args){<br />System.out.pr...
Static & Non-Static<br />class MyClass3<br />	static{<br />System.out.println(“Hey! How is it Possible”);<br />	}<br />}<b...
Objects<br />class MyClass4{<br />	//Body	<br />}<br />class MainMethod{<br />	p s v main(String[ ] a){<br />	MyClass4   m...
Objects<br />class MainMethod{<br />	p s v main(String[ ] a){<br />	MyClass4   myObj=new MyClass4();<br />	MyClass4   myOb...
Objects<br />myObj3=null;<br />
Upcoming SlideShare
Loading in …5
×

Mis Conceptions About The Tiny Java

908 views

Published on

Published in: Education
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
908
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
8
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Mis Conceptions About The Tiny Java

  1. 1. Mis-conceptions about the Java<br />Presenter: Engineer Jokhio Salahuddin Kohistani 07CS24<br />Object Oriented Programming<br />
  2. 2. Contents<br /><ul><li>My First Java Program
  3. 3. Static and Non-Static
  4. 4. Objects
  5. 5. Interfaces
  6. 6. Wrapper Classes</li></li></ul><li>My First Java Program<br />class MyClass{<br /> public static void main(String[ ] args){<br />System.out.println(“Hello World”);<br /> }<br />}<br />
  7. 7. Static & Non-Static<br />class MyClass2{<br />int me=6;<br /> public static void main(String [ ] args){<br />System.out.println(me);<br /> }<br />}<br />
  8. 8. Static & Non-Static<br />class MyClass3<br /> static{<br />System.out.println(“Hey! How is it Possible”);<br /> }<br />}<br />
  9. 9. Objects<br />class MyClass4{<br /> //Body <br />}<br />class MainMethod{<br /> p s v main(String[ ] a){<br /> MyClass4 myObj=new MyClass4();<br /> //other statements<br /> }<br />} <br />
  10. 10. Objects<br />class MainMethod{<br /> p s v main(String[ ] a){<br /> MyClass4 myObj=new MyClass4();<br /> MyClass4 myObj2=myObj;<br />MyClass 4 myObj3=myObj;<br /> //other statements<br /> }<br />} <br />How Many Objects?<br />
  11. 11. Objects<br />myObj3=null;<br />
  12. 12. Interfaces<br />Collections of constants and abstract methods.<br />
  13. 13. Wrapper Classes<br />Classes that allows you to define objects that encapsulates each of the data types.<br />Each of the Basic type as equivalent defined classes.<br />byte Byte<br />short Short<br />int Integer<br />long Long<br />float Float<br />double Double<br />character Character<br />boolean Boolean <br />
  14. 14. Any Questions<br />Thanks…<br />

×