Java

841 views

Published on

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

  • Be the first to like this

No Downloads
Views
Total views
841
On SlideShare
0
From Embeds
0
Number of Embeds
14
Actions
Shares
0
Downloads
0
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Java

  1. 1. Java was born in 1991 and at the beginning its name was Oak. Java was announced in 23 May 1995 on Sun World. On 13 November 2006 Sun Microsystems released it and the Java compiler. On 8 May 2007 SUN released bookcases too. HISTORY
  2. 2. <ul><li>The base programming is composed by determined members: </li></ul><ul><li>variables, that they can be one of this type :string, int, double, long… etc. </li></ul><ul><li>we can find the main member and where programmer can write operations and/or methods that enclose operations. </li></ul>Example of Variables Int a,b=3; Example of main programs: public static void main(String args[]){ _______________________ _______________________ } Example of methods: public int calcolaArea(){ return (base*altezza)/2 }
  3. 3. PROGRAMMING TO OBJECT In programming to objects, OOP, as building an object and recalling the name of the class that will contain all variables of request and the methods of the class. To create an object, you need to create a costructor in the class, that can be, for instance, the class’s variables. Example: public class ex{ private int height; public ex(int n){ height=n; } Private is the visibility level,the others are: public,protected,package.

×