Created
December 14, 2023 23:26
-
-
Save rsaryev/d1831d426c96083bbbd67a159ba95fc5 to your computer and use it in GitHub Desktop.
Multiply list by integer (with restrictions
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const multiply = (n, l) => l.map(a => Math.round(a / (1 / n))); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment