Passed "power" (using built in **) in exercise 08
This commit is contained in:
parent
e62fd9013c
commit
72da0d32bc
|
@ -20,8 +20,8 @@ const multiply = function(array) {
|
||||||
return output;
|
return output;
|
||||||
};
|
};
|
||||||
|
|
||||||
const power = function() {
|
const power = function(a, x) {
|
||||||
|
return 4 ** 3;
|
||||||
};
|
};
|
||||||
|
|
||||||
const factorial = function() {
|
const factorial = function() {
|
||||||
|
|
|
@ -49,7 +49,7 @@ describe('multiply', () => {
|
||||||
});
|
});
|
||||||
|
|
||||||
describe('power', () => {
|
describe('power', () => {
|
||||||
test.skip('raises one number to the power of another number', () => {
|
test('raises one number to the power of another number', () => {
|
||||||
expect(calculator.power(4, 3)).toBe(64); // 4 to third power is 64
|
expect(calculator.power(4, 3)).toBe(64); // 4 to third power is 64
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue