306 Commits

Author SHA1 Message Date
Aditya Bhargava
77a3f8fcc7 Merge pull request #141 from Alexandrshy/issues-140-formatting-problems-and-example-for-greedy-algorithms
Fixed formatting problems
2020-09-14 10:48:25 -05:00
Aditya Bhargava
b2867050d7 Merge pull request #139 from Alexandrshy/issues-138-formatting-problems-and-example-for-dijkstras-algorithm
Fixed formatting problems, added JSDoc
2020-09-14 10:47:56 -05:00
Aditya Bhargava
cb33a62e8a Merge pull request #137 from Alexandrshy/issues-136-formatting-problems-and-example-for-breadth-first-search
Fixed formatting problems, added JSDoc, added example for JS, fixed e…
2020-09-14 10:47:43 -05:00
Aditya Bhargava
0d4a806c14 Merge pull request #135 from Alexandrshy/issues-134-formatting-problems-hash-tables
Fixed formatting problems
2020-09-14 10:47:23 -05:00
Aditya Bhargava
e8a02536f3 Fixed formatting problems, example and JSDoc (#133) 2020-09-14 10:46:57 -05:00
Alexandr Shulaev
34df0a6d08 Fixed formatting problems and JSDoc (#131)
* Fixed formatting problems and JSDoc

* Added returns for JSDoc
2020-09-14 10:46:30 -05:00
Andrii Nyzhnyk
58f1a6e325 clear not needed boilerplate and add author name for the first example 2020-08-23 22:31:33 +03:00
Almas Zaurbekov
977000eb86 python: unit tests for binary search 2020-08-13 01:50:19 +06:00
seanyu4296
2f166a0ee1 Update selection sort 2020-08-05 12:58:43 +00:00
seanyu4296
23f31b4f3f Cleanup packages dhall and remove notes 2020-08-04 11:32:03 +00:00
seanyu4296
32fc3cec95 Add chapter 2 selection sort solution 2020-07-31 07:25:32 +00:00
seanyu4296
3f693b8cf2 update package set 2020-07-31 07:10:55 +00:00
seanyu4296
1a3782d950 update readme with link to main repo 2020-07-31 07:08:50 +00:00
seanyu4296
a59a2b8886 Fix Readme module name 2020-07-31 07:02:40 +00:00
seanyu4296
ad8e62d690 Add purescript solution for chapt 1 2020-07-31 06:58:43 +00:00
=
345d09b69e add recursive soln. 2020-06-03 15:28:01 +02:00
Alexander Launi
16a4ae12f6 Small syntax change in 03_factorial 2020-03-21 18:30:37 -04:00
Alexander Launi
24c91a4a0b Implement factorial using generic mathematics 2020-03-21 17:38:17 -04:00
Alexander Launi
2ff4f42d43 Implement countdown using generic mathematics 2020-03-21 16:43:51 -04:00
Alexander Launi
2aa26293b0 Add factorial examples in Rust 2020-03-21 16:20:51 -04:00
Alexander Launi
64e231a8c6 Add greet example in Rust 2020-03-21 16:16:22 -04:00
Alexander Launi
858e1e71e7 Add recursive countdown example in Rust 2020-03-21 16:08:56 -04:00
Alexander Launi
b0414be22e Add Rust examples to 02_selection_sort 2020-03-21 15:20:34 -04:00
ZGennadiy
cad619574d Update selection sort ES6
Added copy values from original array, because it must be immutable. Without that after call selectionSort origin array will become empty.
2020-03-17 10:24:44 +03:00
Joe Czarnecki
43fb096e64 removed an extra if clause 2020-03-06 14:39:52 +01:00
Joe Czarnecki
4e5867cff1 Update Scala Solutions 2020-03-03 16:54:25 +01:00
Joe Czarnecki
a6502e0af0 Update Scala Solutions 2020-03-03 16:46:16 +01:00
Joe Czarnecki
696a657c6f Create Scala Solutions
I've been working through the book and I was surprised to see there wasn't a Scala Solution here. I created a mutable version as close to the original as possible and immutable recursive version.
2020-03-03 16:16:49 +01:00
fhl43211
e6558351a8 Use lambda function 2020-02-21 09:06:58 -08:00
fhl43211
4fd96f6987 Create cpp file 2020-02-20 17:23:54 -08:00
Ruslan Korolev
891eec2873 fix 04_recursive_max on ruby 2020-01-17 18:29:34 +02:00
Alexander Danilchenko
52a5a7cc24 Changed code style according to new Java versions
Changed long and ugly type declarations with "var" keyword (Java 10).  Also fixed warning about raw usage of HashSet without type specification.
2020-01-12 18:34:55 +02:00
Vladimir Pavlovic
d771cb21a0 Rename 01_longest_common_subsequence to 01_longest_common_subsequence.cpp 2020-01-03 00:46:37 +01:00
TimoSci
ff7ae962c1 edit comments 2019-12-08 13:31:33 +01:00
TimoSci
1f6cf7d460 avoid use of global variables; it is more rubyish to represent a graph as a class 2019-12-08 13:07:44 +01:00
TimoSci
70ddf46cb3 represent record of searched verices as a hash for O(1) lookup 2019-12-08 12:56:36 +01:00
TimoSci
b65c3de283 separate search functionality from seller checking fucntionality according to single responsibility principle 2019-12-08 12:40:40 +01:00
Timo J
c849e75041 More concise Rubyish code.
Hash key checking is not necessary in this case.  If a key doesn't exist in a Hash, Ruby returns nil by default and nil is falsy. Hash key checking would only be necessary if the Hash had been set up with a default value.
2019-12-08 12:03:15 +01:00
BryanChan777
7971852b0e Update README.md 2019-11-23 16:46:38 -08:00
Dmitry Neverovski
b4c440089f Update zero factorial
The Definition of a Zero Factorial
Because zero has no lower numbers but is still in and of itself a number, there is still but one possible combination of how that data set can be arranged: it cannot. This still counts as one way of arranging it, so by definition, a zero factorial is equal to one, just as 1! is equal to one because there is only a single possible arrangement of this data set.
2019-11-20 20:15:19 +03:00
Giorgio
d8da439590 implement recursive binary serach in rust (#93) 2019-11-12 09:19:36 -06:00
Massoud Afrashteh
9dc7611411 Julia samples (#108)
* Add julialang binary search sample

* Add unit test

* Add julialang selection sort sample

* Change julia suffix to jl

* Add recursion and quick sort with tests

* add quick sort

* Add hash table samples

* Add BFS

* Changed file names

* Add dijkstras

* Add Dijkstras test
2019-11-12 09:19:21 -06:00
fdrvrtm
30bbe9cf01 Fix the variable typo and add the function call (#109) 2019-11-12 09:19:09 -06:00
Michael Mkwelele
0377eab73c Add tests for the binary search implementation. (#110) 2019-11-12 09:19:00 -06:00
Michael Mkwelele
184f80127c Add tests for factorial example. (#112) 2019-11-12 09:18:52 -06:00
Felice Forby
4c3bc702f4 Add recursive binary search for ruby (ch. 1) and improve recursive max for ruby (ch. 4) (#113)
* add recursive binary search for ruby

* account for cases with empty lists and lists with only one item

* use p instead of print to show nil value

* add newline at end of file
2019-11-12 09:18:34 -06:00
bigpas
6b9faa9cab fix: naming convention. Min. refactor (#116)
* fix: naming convention. Min. refactor

* add: 05 for Kotlin
2019-11-12 09:18:17 -06:00
Evgeny Samsonov
3a50470e3d Add dijkstras algorithm in golang (#118)
* Golang dijkstra algorithm

* New line in end of file
2019-11-12 09:18:00 -06:00
Yury
9b0288d791 Update 02_recursive_selection_sort.js (#119) 2019-11-12 09:17:35 -06:00
Lu Zhang
878e26217d Update SetCovering.java (#120)
The statesNeeded and finalStations set should be updated after the for loop which finds the bestStation.
2019-10-30 16:32:32 -05:00