Browse Source

docs(froup-prices): correct grammar

1122-buz-zinga
davhojt 2 years ago committed by Dav Hojt
parent
commit
1e9c297c7c
  1. 20
      subjects/group-price/README.md

20
subjects/group-price/README.md

@ -2,11 +2,15 @@
### Instructions
Create a `groupPrice` function, that can find a price in a given string.
The function has to return an array of arrays with the full match of the price ($43.99)
and the groups of that price, the first group(43) and the second group (99).
If there is no match the function returns an empty array.
Example:
"The price is USD12.31"
Expected output:
[["USD12.31","12","31"]]
Create a function named `groupPrice`, that can prices in a given string.
Your function will return s 2D array with the full price breakdown.
If there is no match, your function should return an empty array.
### Example
Given price of `USD12.31`:
```
[["USD12.31", "12", "31"]]
```

Loading…
Cancel
Save