chore(i18n,learn): processed translations (#45165)

This commit is contained in:
camperbot
2022-02-19 12:56:08 +05:30
committed by GitHub
parent 8138a07d52
commit ba14990876
134 changed files with 1540 additions and 1511 deletions

View File

@ -1,6 +1,6 @@
---
id: 5a23c84252665b21eecc8043
title: Sum to 100
title: Somma a 100
challengeType: 5
forumTopicId: 302335
dashedName: sum-to-100
@ -8,33 +8,33 @@ dashedName: sum-to-100
# --description--
Find solutions to the *sum to one hundred* puzzle.
Trova le soluzioni per il puzzle *Somma a cento*.
Add (insert) the mathematical operators **+** or **─** (plus or minus) before any of the digits in the decimal numeric string **123456789** such that the resulting mathematical expression adds up to a particular sum (in this iconic case, **100**).
Aggiungi (inserisci) gli operatori matematici **+** o **─** (p o meno) prima di una qualsiasi delle cifre della stringa numerica decimale **123456789** in modo che l'espressione matematica risultante sommi a una particolare somma (in questo caso iconico, **100**).
Example:
Esempio:
<pre><b>123 + 4 - 5 + 67 - 89 = 100</b></pre>
# --instructions--
Write a function that takes a number as parameter. The function should return an array containing all solutions for the given number. The solutions should be strings representing the expressions. For example: "1+23-456+78-9". Sort the array before returning it.
Scrivi una funzione che prende un numero come parametro. La funzione dovrebbe restituire un array contenente tutte le soluzioni per il numero dato. Le soluzioni dovrebbero essere stringhe che rappresentino le espressioni. Per esempio: "1+23-456+78-9". Ordina l'array prima di restituirlo.
# --hints--
`sumTo100` should be a function.
`sumTo100` dovrebbe essere una funzione.
```js
assert(typeof sumTo100 == 'function');
```
`sumTo100(199)` should return an array.
`sumTo100(199)` dovrebbe restituire un array.
```js
assert(Array.isArray(sumTo100(199)));
```
`sumTo100(199)` should return `["-1+2-3+45+67+89", "123-4+5+6+78-9", "123-4+56+7+8+9"]`.
`sumTo100(199)` dovrebbe restituire `["-1+2-3+45+67+89", "123-4+5+6+78-9", "123-4+56+7+8+9"]`.
```js
assert.deepEqual(sumTo100(199), [
@ -44,13 +44,13 @@ assert.deepEqual(sumTo100(199), [
]);
```
`sumTo100(209)` should return `["1+234+56+7-89"]`.
`sumTo100(209)` dovrebbe restituire `["1+234+56+7-89"]`.
```js
assert.deepEqual(sumTo100(209), ['1+234+56+7-89']);
```
`sumTo100(243)` should return `["-1-234+567-89", "-12+345+6-7-89", "123+45+6+78-9"]`.
`sumTo100(243)` dovrebbe restituire `["-1-234+567-89", "-12+345+6-7-89", "123+45+6+78-9"]`.
```js
assert.deepEqual(sumTo100(243), [
@ -60,7 +60,7 @@ assert.deepEqual(sumTo100(243), [
]);
```
`sumTo100(197)` should return `["1-2-3+45+67+89", "12+34-5+67+89", "123+4-5+6+78-9"]`.
`sumTo100(197)` dovrebbe restituire `["1-2-3+45+67+89", "12+34-5+67+89", "123+4-5+6+78-9"]`.
```js
assert.deepEqual(sumTo100(197), [