Mirzoev Ruslan
49fa7d1a9b
merge: improve median ( #869 )
...
* median
* [/pull/869] make fn pure
* [/pull/869/] pure averageMedian fn
* [/pull/869] formatter
2021-12-20 22:27:05 +05:30
YATIN KATHURIA
ef832f6920
merge: add areaTriangleWithAllThreeSides method in Math/Area.js ( #875 )
2021-12-15 23:00:11 +05:30
YATIN KATHURIA
3d2a48f798
merge: Improve Mean method ( #874 )
2021-12-15 22:58:28 +05:30
YATIN KATHURIA
bbdb5cf38a
merge: Binary Convert ( #865 )
...
* Binary Convert
* Update link
* add more test cases
2021-12-14 11:01:52 +05:30
Rak Laptudirm
f387ff327c
chore: Remove duplicate DigitSum algorithm ( #873 )
...
* Auto-update DIRECTORY.md
* chore: remove duplicate algorithm
* Auto-update DIRECTORY.md
* chore: remove duplicate algorithm tests
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com >
2021-12-11 13:40:11 +05:30
YATIN KATHURIA
4d55b40c9e
merge: Absolute value ( #866 )
2021-12-11 13:29:19 +05:30
YATIN KATHURIA
de2708990d
merge: Add FindMin ( #849 )
2021-11-26 22:12:30 +05:30
YATIN KATHURIA
c1c895bebd
chore: Add PowLogarithmic in Math ( #836 )
...
* Add PowLogarithmic in Math
* add description
2021-11-19 10:40:51 +05:30
ggkogkou
2619ab673f
merge: Added bisection method ( #827 )
...
* feat: Added bisection method
* Auto-update DIRECTORY.md
Co-authored-by: ggkogkou <ggkogkou@ggkogkou.gr >
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com >
2021-10-31 22:30:46 +05:30
Allen Guan
7c39839714
merge: Add LinearSieve.js ( #828 )
2021-10-31 22:28:45 +05:30
Allen Guan
09eebc492a
merge: fix: optimize PrimeFactors ( #823 )
2021-10-29 09:57:16 +05:30
ggkogkou
1cd3b8683a
merge: Created midpoint integration numerical method ( #822 )
...
* Created midpoint integration numerical method
* Auto-update DIRECTORY.md
* Added resources link
* Fixed doxumentation
* Fixed spelling error
Co-authored-by: ggkogkou <ggkogkou@ggkogkou.gr >
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com >
2021-10-28 18:09:40 +05:30
Rak Laptudirm
072523d594
merge: Fix spellings ( #821 )
...
* chore: remove codespell from ci
* feat: add codespell workflow
* fix: codespell workflow
* fix: ignore spellings in directory
* chore: fix spellings
./Dynamic-Programming/KadaneAlgo.js:2: contiguos ==> contiguous
./Dynamic-Programming/KadaneAlgo.js:14: posible ==> possible
* chore: fix spelling
./Dynamic-Programming/SieveOfEratosthenes.js:4: upto ==> up to
* chore: fix spellings
./Dynamic-Programming/MaxNonAdjacentSum.js:22: Exmaple ==> Example
* chore: fix spelling
./Project-Euler/test/Problem010.test.js:4: upto ==> up to
./Project-Euler/test/Problem010.test.js:8: upto ==> up to
./Project-Euler/test/Problem010.test.js:12: upto ==> up to
* chore: fix spelling
./String/AlphaNumericPalindrome.js:10: recieves ==> receives
./String/AlphaNumericPalindrome.js:10: sting ==> string
./String/AlphaNumericPalindrome.js:46: varaible ==> variable
* chore: fix spelling
./String/DiceCoefficient.js:3: stings ==> strings
* chore: fix spelling
./String/test/DiceCoefficient.test.js:9: atleast ==> at least
* chore: fix spelling
./String/test/MaxWord.test.js:8: ba ==> be
* chore: ignore `PermutateString.test.js`
* chore: fix spelling
./String/test/CheckVowels.test.js:62: occurances ==> occurrences
* chore: ignore `SubsequenceRecursive.js`
* chore: fix spelling
./Conversions/TemperatureConversion.js:2: arguement ==> argument
* chore: fix spelling
./Conversions/RailwayTimeConversion.js:7: Formate ==> Format
./Conversions/RailwayTimeConversion.js:8: Formate ==> Format
* chore: remove Linear Algebra
The deleted directory hosted a package which are not accepted by this repository.
* Auto-update DIRECTORY.md
* chore: fix spelling
* chore: fix spellings
* merge: Created composite Simpson's integration method. Tests included. (#819 )
* Created composite Simpson's integration method.Tests included
* Minor corrections
* Auto-update DIRECTORY.md
* Styled with standard.js
* chore: remove blank line
* chore: remove blank line
Co-authored-by: ggkogkou <ggkogkou@ggkogkou.gr >
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com >
Co-authored-by: Rak Laptudirm <raklaptudirm@gmail.com >
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: remove codespell from ci
* feat: add codespell workflow
* fix: codespell workflow
* fix: ignore spellings in directory
* chore: fix spellings
./Dynamic-Programming/KadaneAlgo.js:2: contiguos ==> contiguous
./Dynamic-Programming/KadaneAlgo.js:14: posible ==> possible
* chore: fix spelling
./Dynamic-Programming/SieveOfEratosthenes.js:4: upto ==> up to
* chore: fix spellings
./Dynamic-Programming/MaxNonAdjacentSum.js:22: Exmaple ==> Example
* chore: fix spelling
./Project-Euler/test/Problem010.test.js:4: upto ==> up to
./Project-Euler/test/Problem010.test.js:8: upto ==> up to
./Project-Euler/test/Problem010.test.js:12: upto ==> up to
* chore: fix spelling
./String/AlphaNumericPalindrome.js:10: recieves ==> receives
./String/AlphaNumericPalindrome.js:10: sting ==> string
./String/AlphaNumericPalindrome.js:46: varaible ==> variable
* chore: fix spelling
./String/DiceCoefficient.js:3: stings ==> strings
* chore: fix spelling
./String/test/DiceCoefficient.test.js:9: atleast ==> at least
* chore: fix spelling
./String/test/MaxWord.test.js:8: ba ==> be
* chore: ignore `PermutateString.test.js`
* chore: fix spelling
./String/test/CheckVowels.test.js:62: occurances ==> occurrences
* chore: ignore `SubsequenceRecursive.js`
* chore: fix spelling
./Conversions/TemperatureConversion.js:2: arguement ==> argument
* chore: fix spelling
./Conversions/RailwayTimeConversion.js:7: Formate ==> Format
./Conversions/RailwayTimeConversion.js:8: Formate ==> Format
* chore: remove Linear Algebra
The deleted directory hosted a package which are not accepted by this repository.
* Auto-update DIRECTORY.md
* chore: fix spelling
* chore: fix spellings
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: fix spelling
* chore: no need to check filenames
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com >
Co-authored-by: ggkogkou <76820848+ggkogkou@users.noreply.github.com >
Co-authored-by: ggkogkou <ggkogkou@ggkogkou.gr >
2021-10-28 15:37:43 +05:30
ggkogkou
7722870183
merge: Created composite Simpson's integration method. Tests included. ( #819 )
...
* Created composite Simpson's integration method.Tests included
* Minor corrections
* Auto-update DIRECTORY.md
* Styled with standard.js
* chore: remove blank line
* chore: remove blank line
Co-authored-by: ggkogkou <ggkogkou@ggkogkou.gr >
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com >
Co-authored-by: Rak Laptudirm <raklaptudirm@gmail.com >
2021-10-28 15:07:07 +05:30
Dumby
7c2f19b691
merge: Rename 2 filenames to follow PascalCase ( #816 )
...
* Added LucasSeries
* Added more tests and renamed function
* Changed RangeError to TypeError
* Added Aliquot Sum and tests
* Fix ALiquot tests, need to learn how to use Jest
* Added some explanation for the Aliquot sum
* Change file names of DecimalIsolate & IsOdd to Pascal case
2021-10-26 16:56:45 +05:30
Dumby
502aec24cb
merge: Added Aliquot Sum Implementation ( #810 )
...
* Added LucasSeries
* Added more tests and renamed function
* Changed RangeError to TypeError
* Added Aliquot Sum and tests
* Fix ALiquot tests, need to learn how to use Jest
* Added some explanation for the Aliquot sum
2021-10-26 15:00:07 +05:30
Dumby
69a397cc33
merge: Added LucasSeries Implementation ( #808 )
...
* Added LucasSeries
* Added more tests and renamed function
* Changed RangeError to TypeError
2021-10-25 10:03:02 +05:30
Dhana D
e8d862ca94
merge: Added manhattan distance and euclidean distance for distance 2 points task ( #809 )
...
* Added Hex to Binary conversion
* Update Conversions/HexToBinary.js
Co-authored-by: Rak Laptudirm <raklaptudirm@gmail.com >
* Update Conversions/HexToBinary.js
Co-authored-by: Rak Laptudirm <raklaptudirm@gmail.com >
* Update Conversions/HexToBinary.js
Co-authored-by: Rak Laptudirm <raklaptudirm@gmail.com >
* Update Conversions/HexToBinary.js
Co-authored-by: Rak Laptudirm <raklaptudirm@gmail.com >
* Fix errors
* fix: typo
* Added Manhattan Distance Algorithm
Co-authored-by: Rak Laptudirm <raklaptudirm@gmail.com >
2021-10-25 09:26:53 +05:30
Dumby
cd3974c457
merge: Added Sum of GP ( #807 )
2021-10-23 23:14:01 +05:30
Rak Laptudirm
22ce7603e4
fix: standard style issues
2021-10-21 22:59:56 +05:30
Rak Laptudirm
d38ebe5199
chore: Merge pull request #768 from lvlte/issues/720
...
Changes for consolidation
2021-10-21 19:32:55 +05:30
VinWare
e92e2e3926
Added a short explanation of the Ext Euc Algo
2021-10-21 18:31:39 +05:30
VinWare
79c7ce45c8
Fixed != to !== and ran npm run style
2021-10-21 15:57:20 +05:30
VinWare
56b29cab25
Merge branch 'TheAlgorithms:master' into master
2021-10-21 15:09:26 +05:30
VinWare
5ccfafecbb
npm run style result
2021-10-21 15:06:33 +05:30
VinWare
fe56f54f82
Added Extended Euclidean Algorithm (ExtendedEuclideanGCD.js) to Maths folder, along with relevant test
2021-10-21 14:58:12 +05:30
Rak Laptudirm
8352d260b8
chore: Merge pull request #794 from Badhusha-Akhthaar/master
...
Added new Mathematical algorithm : Figurate Numbers
2021-10-21 14:38:25 +05:30
Badhusha
43585378d8
Fixed as per standard.js
2021-10-21 10:01:21 +05:30
Badhusha-Akhthaar
915ca4c7ef
Added new Mathematical algorithm , Figurate Numbers
...
Algorithm for checking whether input number does belong to any type of figurate numbers
2021-10-17 14:12:32 +05:30
arthurvergacas
fa1abf4e1c
Minor fixes
...
- Add some explanation and links about Carmichael Numbers
- Remove explanation about in-built function Math.random()
2021-10-16 11:37:15 -03:00
arthurvergacas
ffb138adb1
Minor fixes
...
- Add default number of iterations
- Correct "corner cases" to "edge cases"
- Make clear which bounds are inclusive and which are exclusive
2021-10-15 12:21:48 -03:00
Roland Hummel
c5e44d498a
A few suggestions / modifications / fixes
...
It seems you've accidentally swapped the implementation and the test file :)
The overall comment describing the algorithm (VERY nice doc, by the way) is not "proper" JSdoc => only one leading asterisk. It's generally considered good style to start a comment block (both JSdoc and regular comments) with a single, short sentence.
Further down, there were some git hiccups, most likely caused by merge conflicts?
2021-10-14 22:32:56 +02:00
arthurvergacas
3c2fdf7582
Add Fermat Primality Test
2021-10-14 15:15:49 -03:00
Eric Lavault
9212e6d684
Remove live code & console.log, leave examples as comments (Geometry, Graphs, Maths).
2021-10-10 17:55:08 +02:00
Eric Lavault
3f32320c85
Comply with ESM. Convert live code example to Jest test.
2021-10-09 13:25:34 +02:00
Eric Lavault
cbe7e0c89f
Comply with ESM syntax.
2021-10-09 13:18:40 +02:00
Roland Hummel
b13b12e88c
chore: merge Fix/742 migrate doctest to jest ( #749 )
...
* Remove QuickSelect doctest
There are more Jest test cases already.
* Remove AverageMedian doctest
Already migrated to jest
* Migrate doctest for BinaryExponentiationRecursive.js
(also remove inline "main" test method)
* Migrate doctest for EulersTotient.js
(also remove inline "main" test method)
* Migrate doctest for PrimeFactors.js
(also remove inline "main" test method)
* Migrate doctest for BogoSort.js
Re-write prototype-polluting helper methods, too.
(also remove inline test driver code)
* Migrate doctest for BeadSort.js
(also remove inline test driver code)
* Migrate doctest for BucketSort.js
(also remove inline test driver code)
* Migrate doctest for CocktailShakerSort.js
(also remove inline test driver code)
* Migrate doctest for MergeSort.js
(also remove inline test driver code)
* Migrate doctest for QuickSort.js
(also remove inline test driver code)
* Migrate doctest for ReverseString.js
(also remove inline test driver code)
* Migrate doctest for ReverseString.js
* Migrate doctest for ValidateEmail.js
* Migrate doctest for ConwaysGameOfLife.js
(remove the animate code, too)
* Remove TernarySearch doctest
Already migrated to jest
* Migrate doctest for BubbleSort.js
(also remove inline test driver code)
* Remove doctest from CI and from dependencies
relates to #742
fixes #586
* Migrate doctest for RgbHsvConversion.js
* Add --fix option to "standard" npm script
* Migrate doctest for BreadthFirstSearch.js
(also remove inline test driver code)
* Migrate doctest for BreadthFirstShortestPath.js
(also remove inline test driver code)
* Migrate doctest for EulerMethod.js
(also remove inline test driver code)
Move manual test-code for plotting stuff in the browser in a distinct file, too. Those "*.manual-test.js" files are excluded from the UpdateDirectory.mjs script, as well.
* Migrate doctest for Mandelbrot.js
(also remove inline test driver code & moved manual drawing test into a *.manual-test.js)
* Migrate doctest for FloodFill.js
* Migrate doctest for KochSnowflake.js
(also move manual drawing test into a *.manual-test.js)
* Update npm lockfile
* Update README and COMMITTING with a few bits & bobs regarding testing & code quality
2021-10-07 12:33:38 +05:30
Sajeeb Ahamed
82d1c2a6bd
Merge branch 'master' into master
2021-10-06 00:00:47 +06:00
Keshav Bohra
1589263947
fixed some spellings
2021-10-05 12:49:23 +05:30
Sajeeb Ahamed
bf088c0646
✨ add an algorithm for checking a year is a leap year or not
2021-10-04 01:20:08 +06:00
Legendary Noob
b3b4ad43a3
chore: Added Sum of Digits Implementation ( #684 )
...
* Added the main logic, need to work on Tests
* Added tests for SOD
* Fix typo and add Wikipedia link in comments
* Fix mistake in SumOfDigitsUsingStrings
I intended to initially write a different implementation but I wrote something else 🤦♂️
* Converted Spacing from Tabs to Spaces
* Oops, forgot about the test file
* Fixed semicolon problems...
* Oops, I missed a few semicolons
* Linting is hell TwT
Co-authored-by: SpiderMath <{ID}+{username}@users.noreply.github.com >
2021-09-13 19:41:28 +05:30
Suryapratap Singh
5e3106e81b
fix, self-contained gcd method
2021-09-07 18:10:47 +05:30
Suryapratap Singh
5a8bb67124
fix the string method problem
2021-09-07 17:55:11 +05:30
Suryapratap Singh
800308f216
add CheckKishnamurthyNumber
2021-09-07 03:33:17 +05:30
Suryapratap Singh
7fb345b4bd
fix typing style
2021-09-07 03:23:38 +05:30
Suryapratap Singh
617ec6ba27
fix number checking
2021-09-07 03:23:02 +05:30
Suryapratap Singh
d79e2f71fa
add CoPrimeCheck method
2021-09-07 03:10:17 +05:30
Suryapratap Singh
09ce0c76a6
change the GetGCD method to GetEuclidGCD method
2021-08-31 13:53:49 +05:30
Suryapratap Singh
92b8b46f36
add type checking
2021-08-31 13:48:39 +05:30
Suryapratap Singh
c67b0e9f1d
add ReverseNumber method
2021-08-31 03:53:53 +05:30