From 848079a6f9f8f9b4c9e79a27ac8e528ea05557d6 Mon Sep 17 00:00:00 2001 From: chip777 Date: Tue, 1 Feb 2022 22:34:52 +0300 Subject: [PATCH 1/3] lesson4 --- 1.html | 56 +++++++++++++++++++++++++ 2.html | 126 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 3.html | 68 +++++++++++++++++++++++++++++++ 3 files changed, 250 insertions(+) create mode 100644 1.html create mode 100644 2.html create mode 100644 3.html diff --git a/1.html b/1.html new file mode 100644 index 0000000..e17c66f --- /dev/null +++ b/1.html @@ -0,0 +1,56 @@ + + + + + Homework + + + + + + \ No newline at end of file diff --git a/2.html b/2.html new file mode 100644 index 0000000..764335d --- /dev/null +++ b/2.html @@ -0,0 +1,126 @@ + + + + + Homework + + + + + + \ No newline at end of file diff --git a/3.html b/3.html new file mode 100644 index 0000000..36a3218 --- /dev/null +++ b/3.html @@ -0,0 +1,68 @@ + + + + + Homework + + + + + + \ No newline at end of file From 76e9cdbe8eceeb6b6aee39e63aefe4e6df3f854a Mon Sep 17 00:00:00 2001 From: chip777 Date: Thu, 3 Feb 2022 19:46:40 +0300 Subject: [PATCH 2/3] =?UTF-8?q?=D0=B8=D1=81=D0=BF=D1=80=D0=B0=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=D0=B8=D0=B5=20=D0=BE=D1=88=D0=B8=D0=B1=D0=BE=D0=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 1.html | 14 +++++++------- 2.html | 10 +++++----- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/1.html b/1.html index e17c66f..5d1ce01 100644 --- a/1.html +++ b/1.html @@ -25,27 +25,27 @@ this.cost = cost; } - ProductES5.prototype.make25Discount = function (){ - this.cost = this.cost - this.cost*25/100; + ProductES5.prototype.make25Discount = function () { + this.cost = this.cost - this.costи*25 / 100; } - const prod1 = new ProductES5('orange',55); + const prod1 = new ProductES5('orange', 55); console.log(`Name: ${prod1.name}, cost: ${prod1.cost}`); prod1.make25Discount(); console.log(`Name: ${prod1.name}, cost: ${prod1.cost}`); class ProductES6 { - constructor(name,cost){ + constructor(name, cost) { this.name = name; this.cost = cost; } - make25Discount(){ - this.cost = this.cost - this.cost*25/100; + make25Discount() { + this.cost = this.cost - this.cost * 25 / 100; } } - const prod2 = new ProductES6('apple',100); + const prod2 = new ProductES6('apple', 100); console.log(`Name: ${prod2.name}, cost: ${prod2.cost}`); prod2.make25Discount(); diff --git a/2.html b/2.html index 764335d..99a5684 100644 --- a/2.html +++ b/2.html @@ -69,11 +69,11 @@ class PostES6{ - constructor(author, text){ - this.author = author; - this.text = text; - this.modified = new Date(); // - } + constructor(author, text) { + this.author = author; + this.text = text; + this.modified = new Date(); // + } edit(text){ this.text = text; this.modified = new Date(); From c1abbc4b255f955bd77b7c4bb90e2717e39969e7 Mon Sep 17 00:00:00 2001 From: chip777 Date: Thu, 3 Feb 2022 19:50:57 +0300 Subject: [PATCH 3/3] =?UTF-8?q?=D0=B8=D1=81=D0=BF=D1=80=D0=B0=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=D0=B8=D0=B5=20=D0=BE=D1=88=D0=B8=D0=B1=D0=BE=D0=BA?= =?UTF-8?q?2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 1.html | 2 +- 2.html | 16 ++++++++-------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/1.html b/1.html index 5d1ce01..70dde75 100644 --- a/1.html +++ b/1.html @@ -26,7 +26,7 @@ } ProductES5.prototype.make25Discount = function () { - this.cost = this.cost - this.costи*25 / 100; + this.cost = this.cost - this.cost * 25 / 100; } const prod1 = new ProductES5('orange', 55); diff --git a/2.html b/2.html index 99a5684..2f55190 100644 --- a/2.html +++ b/2.html @@ -50,13 +50,13 @@