-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlesson_poo.json
1 lines (1 loc) · 1.78 KB
/
lesson_poo.json
1
{"3":"Welcome in this third POO Lesson.. Today we will learn about static type.. Basically, we call 'static type' the type of the declaration.. if you declare 'A a= new C()', the 'static type' of a is A.. This is it for this short POO lesson about static type, see you for another one..","2":"Welcome in this second POO Lesson.. Today let me introduce you inheritance.. You can declare a class B which inherit another class A.. you write it this way 'A a= new B()'.. But this 'B = new A()' is wrong.. You have to add the instruction 'super();' in the constructor of B for the code to compile.. This is it for this POO lesson, see you for another one..","1":"Welcome in this first POO Lesson.. Today we will learn about Java syntax.. If you write 'private' the field won't be accessible out of the class.. If you declare a variable of a certain type, you can't affect it another type.. Don't forget to add ';' at the end of every line of code.. This is it for this POO lesson, see you for another one..","5":"Welcome in this fifth POO Lesson.. Today we will learn more about inheritance!. We learned that a class B can inherit from another class A.. By doing this an infinite number of class can inherit of class A.. But be careful, you can't inherit from two different classes !. Don't forget to add the instruction 'super()' to the constructor of the class.. This it if for this POO lesson..","4":"Welcome in this fourth POO Lesson.. Today we will learn about some properties of instance.. Some class can be not instanciate.. if you set the constructor as 'private' of if you declare the class as 'abstract' you won't be able to instanciate an object for this class.. And just before you leave, remember that, an interface can be the static type for an object.. This is it for this POO lesson, see you for another one.."}