Update task.md
This commit is contained in:
parent
c11e773e70
commit
e09ea79a3b
1 changed files with 1 additions and 1 deletions
|
@ -6,7 +6,7 @@ importance: 5
|
||||||
|
|
||||||
Create a constructor function `Calculator` that creates objects with 3 methods:
|
Create a constructor function `Calculator` that creates objects with 3 methods:
|
||||||
|
|
||||||
- `read()` asks for two values using `prompt` and stores each of them in a unique object property.
|
- `read()` prompts for two values and saves them as object properties with names `a` and `b` respectively.
|
||||||
- `sum()` returns the sum of these properties.
|
- `sum()` returns the sum of these properties.
|
||||||
- `mul()` returns the multiplication product of these properties.
|
- `mul()` returns the multiplication product of these properties.
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue