Fix formatting

This commit is contained in:
Isabelle Viktoria Maciohsek
2022-01-30 11:40:42 +02:00
parent c56b5a11da
commit 42c503135e
7 changed files with 7 additions and 7 deletions

View File

@ -7,7 +7,7 @@ lastUpdated: 2021-01-06T22:47:48+02:00
Calculates the nth root of a given number.
- Use `Math.pow()` to calculate `x` to the power of `1/n` which is equal to the nth root of `x`.
- Use `Math.pow()` to calculate `x` to the power of `1 / n` which is equal to the nth root of `x`.
```js
const nthRoot = (x, n) => Math.pow(x, 1 / n);