From a45492a8009304e5a9b69ac6bec15fbb35e66851 Mon Sep 17 00:00:00 2001 From: upupming Date: Sun, 15 Jul 2018 13:28:30 +0800 Subject: [PATCH] Fixed: function name not match --- .../06-constructor-new/4-calculator-extendable/task.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/1-js/04-object-basics/06-constructor-new/4-calculator-extendable/task.md b/1-js/04-object-basics/06-constructor-new/4-calculator-extendable/task.md index 1f6368c0..cc5453ce 100644 --- a/1-js/04-object-basics/06-constructor-new/4-calculator-extendable/task.md +++ b/1-js/04-object-basics/06-constructor-new/4-calculator-extendable/task.md @@ -17,7 +17,7 @@ The task consists of two parts. alert( calc.calculate("3 + 7") ); // 10 ``` -2. Then add the method `addOperator(name, func)` that teaches the calculator a new operation. It takes the operator `name` and the two-argument function `func(a,b)` that implements it. +2. Then add the method `addMethod(name, func)` that teaches the calculator a new operation. It takes the operator `name` and the two-argument function `func(a,b)` that implements it. For instance, let's add the multiplication `*`, division `/` and power `**`: