mirror of
https://github.com/TheAlgorithms/JavaScript.git
synced 2025-07-06 17:50:39 +08:00

Perfect{Square, Cube}
(#1071)
* Make `PerfectCube` more correct and readable * Add negative and Infinity tests * Fixed comment formatting * Realized BigInt support is unnecessary The algorithm would be exactly the same, so there's no added educational value * Update PerfectCube.js * Remove space * Update PerfectCube.js Now `isInt` is replaced by `isFinite`, because `isInt` is a redundant check * Update PerfectCube.js Remove dot * Parity between `PerfectSquare` and `PerfectCube` * Update PerfectSquare.test.js Fixed the old copy-paste error that said "cube" instead of "square". And added `Infinity` test
The Algorithms - JavaScript
JavaScript Repository of TheAlgorithms, which implements various algorithms and data structures in JavaScript.
These implementations are for demonstrative purposes only. Dedicated implementations of these algorithms and data structures are much better for performance and security reasons. We also do not provide any guarantee for api stability.
Before contributing to this repository, make sure to read our Contribution Guidelines. You can look at other TheAlgorithms Repositories or the issues with a "help wanted" label for inspiration regarding what to implement. Our maintainers will guide you through how to make your contribution properly if you make any mistakes. The names of the maintainers of this repository is listed in the CODEOWNERS file.
You can find a list of the algorithms currently in the repository in the directory. Explanations of many of the algorithms can be found in the wiki.
Description
Algorithms and Data Structures implemented in JavaScript for beginners, following best practices.
algorithmalgorithm-challengesalgorithmsalgorithms-implementedcipherconversionscryptographydata-structureshacktoberfestjavascriptmathematicssearchsortsorting-algorithms
Readme
GPL-3.0
142 MiB
Languages
JavaScript
100%