File tree Expand file tree Collapse file tree 3 files changed +68
-1
lines changed
Expand file tree Collapse file tree 3 files changed +68
-1
lines changed Original file line number Diff line number Diff line change 11{
2- "liveServer.settings.port" : 5501
2+ "liveServer.settings.port" : 5502
33}
Original file line number Diff line number Diff line change 1+ <!DOCTYPE html>
2+ < html lang ="en ">
3+ < head >
4+ < meta charset ="UTF-8 ">
5+ < meta name ="viewport " content ="width=device-width, initial-scale=1.0 ">
6+ < title > Document</ title >
7+ </ head >
8+ < body >
9+ < script src ="script.js "> </ script >
10+ </ body >
11+ </ html >
Original file line number Diff line number Diff line change 1+ // // protyotype
2+
3+ // university={
4+ // name:"UoK",
5+ // teacher:200,
6+ // salary(){
7+ // console.log("Salary is 200 usd")
8+ // }
9+
10+ // }
11+
12+ // bonus={
13+ // extra:"30%"
14+ // }
15+
16+ // bonus.__proto__=university
17+
18+ // //class
19+
20+ // class universal {
21+ // wages(){
22+ // console.log("Wages are 20%")
23+ // }
24+
25+ // controller="admin"
26+
27+ // employeename(ename){
28+ // this.empl=ename
29+ // }
30+ // }
31+
32+ // employee1= new universal()
33+ // employee1.employeename("haitham")
34+
35+ // employee2=new universal()
36+ // employee2.employeename("hafsa")
37+
38+
39+ //inheritance
40+
41+ class Person {
42+ sleep ( ) {
43+ console . log ( "sleep" ) ;
44+ }
45+ eat ( ) {
46+ console . log ( "eat" ) ;
47+ }
48+ }
49+
50+ class engineer extends Person {
51+ work ( ) {
52+ console . log ( "build diffrent new things" ) ;
53+ }
54+ }
55+
56+ let obj = new engineer ( ) ;
You can’t perform that action at this time.
0 commit comments