...Linked List file algorithm.
* Bug: Added exit condition to the linked list menu
* revert back
* fix: added exit condition to the linked list display menu
* update
Co-authored-by: David Leal <halfpacho@gmail.com>
* fix: CI workflow not being able to commit to...
...the `master` branch.
This is due to the branch protection: we cannot add `github-actions` as administrator to skip the protection. So let's add my name which has administrator permissions, that should work.
UNTESTED, might not work.
* Let's test it
* updating DIRECTORY.md
Co-authored-by: David <Panquesito7@users.noreply.github.com>
* feat : Implemented Inverse Fast Fourier Transform
Slightly different from fast Fourier transform
Just the om variable declared in line 40 is divided by n
and swapping the testing inputs with testing outputs .
* Update numerical_methods/Inverse_fast_fourier_transform.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update numerical_methods/Inverse_fast_fourier_transform.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update numerical_methods/Inverse_fast_fourier_transform.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* formatting filenames d7f9a946
* updating DIRECTORY.md
* fix : optimized the code
* Apply suggestions from code review
Co-authored-by: David Leal <halfpacho@gmail.com>
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: Ayaan Khan <ayaankhan98@gmail.com>
* Create reverse_binary_tree.cpp
* Added documentation
Added Documentation for the level_order_traversal() function, and implemented a print() function to display the tree to STDOUT
* Added documentation
* Renamed tests to test
* Fixed issue with incorrect using statement
* updating DIRECTORY.md
* clang-format and clang-tidy fixes for fb86292d
* Added Test cases
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Changed int to int64_t
* Updated documentation wording
* Rewrote node struct and file structure
* Added Circular Linked List
* Update doc
* Wrote bulk of code, added documentation
* clang-format and clang-tidy fixes for 06f11f1e
* Update operations_on_datastructures/circular_linked_list.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/circular_linked_list.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* clang-format and clang-tidy fixes for 25ed3ea0
* Added parameter documentation
* Added destructor for CircularLinkedList
* Fixed memory bug
* Update circular_linked_list.cpp
* Update circular_linked_list.cpp
* Added move constructor and assignment operator
* clang-format and clang-tidy fixes for b36e4736
* Fixed copy and move operators/constructors and added documentation
* clang-format and clang-tidy fixes for 24d3b9c2
* Added missing returns
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: David Leal <halfpacho@gmail.com>
Co-authored-by: Abhinn Mishra <49574460+mishraabhinn@users.noreply.github.com>
* fix: rewrite prime numbers using linear sieve
* fix code scanning error
* clang-format and clang-tidy fixes for 0afd463b
* fix sign-compare warning
* clang-format and clang-tidy fixes for 6ddff0f7
Co-authored-by: David Leal <halfpacho@gmail.com>
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
* [feat/fix/docs]: Improvements in the...
...`backtracking` folder, and minor fixes in the `others/iterative_tree_traversals.cpp` and the `math/check_prime.cpp` files.
* clang-format and clang-tidy fixes for 9cc3951d
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: Abhinn Mishra <49574460+mishraabhinn@users.noreply.github.com>
* Create reverse_binary_tree.cpp
* Added documentation
Added Documentation for the level_order_traversal() function, and implemented a print() function to display the tree to STDOUT
* Added documentation
* Renamed tests to test
* Fixed issue with incorrect using statement
* updating DIRECTORY.md
* clang-format and clang-tidy fixes for fb86292d
* Added Test cases
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Changed int to int64_t
* Updated documentation wording
* Rewrote array_left_rotation
* Modified doc, fixed bug in shifting logic
Fixed a mistake that would cause the array to shift incorrectly
* clang-format and clang-tidy fixes for bd135686
* Update operations_on_datastructures/array_left_rotation.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* changed int to size_t
* clang-format and clang-tidy fixes for 00e7daaf
* clang-format and clang-tidy fixes for ed2aa3a7
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: David Leal <halfpacho@gmail.com>
Co-authored-by: Abhinn Mishra <49574460+mishraabhinn@users.noreply.github.com>
* Create reverse_binary_tree.cpp
* Added documentation
Added Documentation for the level_order_traversal() function, and implemented a print() function to display the tree to STDOUT
* Added documentation
* Renamed tests to test
* Fixed issue with incorrect using statement
* updating DIRECTORY.md
* clang-format and clang-tidy fixes for fb86292d
* Added Test cases
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Changed int to int64_t
* Updated documentation wording
* Added reference to intersection of two arrays
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: David Leal <halfpacho@gmail.com>
* feat: added math/area.cpp
* feat: added surface area of sphere, cube and cylinder
* docs: modified @brief
* feat: changed to template functions
* test: added 2 test cases for square_area()
* test: added 3rd test case
* [test/docs] added more test cases and docs for them
* docs: added @details
* updating DIRECTORY.md
* fix: changed from math.h to cmath
Co-authored-by: David Leal <halfpacho@gmail.com>
* feat: added algorithms to the math namespace
Co-authored-by: David Leal <halfpacho@gmail.com>
* fix: call functions from the math namespace for testing
* fix: style indentation
Co-authored-by: David Leal <halfpacho@gmail.com>
* fix: style indentation
Co-authored-by: David Leal <halfpacho@gmail.com>
* feat: uses uint16_t instead of int for testing
* docs: added comments for testing variables
* fix: style guide
Co-authored-by: David Leal <halfpacho@gmail.com>
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: David Leal <halfpacho@gmail.com>
* Add files via upload
# Class Based DSU
-Using Path Compression to get the best time complexity O(1)
-Using Union Rank to keep track of changes using parent(p) O(logN)
* Class based DSU : Path Compression O(1) and Union Rank O(logN)
* made changes to satisfy the meets of the PR
changes made to satisfy the needs of the PR
- used base lib instead of <bits/stdc++.h>
- changed all stdin's and included pre-declared test cases
* removed stdin for testing
* changed file name from upper case to lower case
* made necessary changes
* Delete DSU_union_rank.cpp
* Delete DSU_path_compresssion.cpp
* added explicit to contructors, return 0, n=dec
* Delete dsu_path_compresssion.cpp
* added documentations, to match the typical structure
Added @brief @details @author @param @returns
* Update data_structures/dsu_union_rank.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_union_rank.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* added self-implementation test cases, changed int to uint64_t
* std::cout after assert
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_union_rank.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* updating DIRECTORY.md
* clang-format and clang-tidy fixes for b8c37d09
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* documentation changes
* Update dsu_union_rank.cpp
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_union_rank.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_union_rank.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_union_rank.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* clang-format and clang-tidy fixes for 18843179
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_path_compression.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update data_structures/dsu_union_rank.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* clang-format and clang-tidy fixes for 5c24d9a9
* Update data_structures/dsu_union_rank.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
Co-authored-by: David Leal <halfpacho@gmail.com>
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: Abhinn Mishra <49574460+mishraabhinn@users.noreply.github.com>
Co-authored-by: Ayaan Khan <ayaankhan98@gmail.com>
* Create reverse_binary_tree.cpp
* Added documentation
Added Documentation for the level_order_traversal() function, and implemented a print() function to display the tree to STDOUT
* Added documentation
* Renamed tests to test
* Fixed issue with incorrect using statement
* updating DIRECTORY.md
* clang-format and clang-tidy fixes for fb86292d
* Added Test cases
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Changed int to int64_t
* Updated documentation wording
* Reused code from union_of_two_arrays and modified for intersection
* Fixed bug and corrected test output
* Renamed file to better meet filename guidelines
* updating DIRECTORY.md
* clang-format and clang-tidy fixes for e653f77a
* Changed integer type from int64_t to int32_t
* Added reference to similar union_of_two_arrays file
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: David Leal <halfpacho@gmail.com>
Co-authored-by: Abhinn Mishra <49574460+mishraabhinn@users.noreply.github.com>
* Create reverse_binary_tree.cpp
* Added documentation
Added Documentation for the level_order_traversal() function, and implemented a print() function to display the tree to STDOUT
* Added documentation
* Renamed tests to test
* Fixed issue with incorrect using statement
* updating DIRECTORY.md
* clang-format and clang-tidy fixes for fb86292d
* Added Test cases
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Changed int to int64_t
* Updated documentation wording
* Rewrote array_right_rotation by modifying code from array_left_rotation
* Minor documentation changes
* clang-format and clang-tidy fixes for 16672f02
* Update operations_on_datastructures/array_right_rotation.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Changed int to size_t
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: David Leal <halfpacho@gmail.com>
* Create reverse_binary_tree.cpp
* Added documentation
Added Documentation for the level_order_traversal() function, and implemented a print() function to display the tree to STDOUT
* Added documentation
* Renamed tests to test
* Fixed issue with incorrect using statement
* updating DIRECTORY.md
* clang-format and clang-tidy fixes for fb86292d
* Added Test cases
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Changed int to int64_t
* Updated documentation wording
* Fixed wrong integer type
Changed int64_t to int32_t
* clang-format and clang-tidy fixes for 2af706b1
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: David Leal <halfpacho@gmail.com>
* updated the code to make it more efficient
* Update math/check_prime.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update math/check_prime.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Apply suggestions from code review
Co-authored-by: David Leal <halfpacho@gmail.com>
* feat: added a1z26 cipher
* updating DIRECTORY.md
* clang-format and clang-tidy fixes for 6e5b6be0
* Update ciphers/a1z26_cipher.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* clang-format and clang-tidy fixes for 36edde81
* fix: brace style
Co-authored-by: David Leal <halfpacho@gmail.com>
* [feat/fix]: uses uint8_t for maps instead of int
* clang-format and clang-tidy fixes for ef211d41
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: David Leal <halfpacho@gmail.com>
* Create reverse_binary_tree.cpp
* Added documentation
Added Documentation for the level_order_traversal() function, and implemented a print() function to display the tree to STDOUT
* Added documentation
* Renamed tests to test
* Fixed issue with incorrect using statement
* updating DIRECTORY.md
* clang-format and clang-tidy fixes for fb86292d
* Added Test cases
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Changed int to int64_t
* Updated documentation wording
* Added namespace and print function
Added the operations_on_datastructures namespace and created a function to print a vector.
* Added implementation of union for two arrays
* Fixed bug with initialization of indexes and added test case
* Added test cases
* Modified references to const &
* Renamed file to meet filename guidelines better
* updating DIRECTORY.md
* Update operations_on_datastructures/union_of_two_arrays.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/union_of_two_arrays.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/union_of_two_arrays.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Made changes to documentation
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: David Leal <halfpacho@gmail.com>
* Create reverse_binary_tree.cpp
* Added documentation
Added Documentation for the level_order_traversal() function, and implemented a print() function to display the tree to STDOUT
* Added documentation
* Renamed tests to test
* Fixed issue with incorrect using statement
* updating DIRECTORY.md
* clang-format and clang-tidy fixes for fb86292d
* Added Test cases
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update operations_on_datastructures/reverse_binary_tree.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Changed int to int64_t
* Updated documentation wording
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: David Leal <halfpacho@gmail.com>
* feat: add atbash_cipher
* [test/fix]: test case expected result
* docs: added comments for main and test function
* doc: changed brief for test function
Co-authored-by: David Leal <halfpacho@gmail.com>
* updating DIRECTORY.md
* doc: fixed test comment
Co-authored-by: David Leal <halfpacho@gmail.com>
* [feat/fix]: made test function static
Co-authored-by: David Leal <halfpacho@gmail.com>
* doc: added author comment
Co-authored-by: David Leal <halfpacho@gmail.com>
* fix: brace style
Co-authored-by: David Leal <halfpacho@gmail.com>
* doc: modified file description and added comments for test function
* doc: added comment for #include <iostream>
Co-authored-by: David Leal <halfpacho@gmail.com>
* doc: added description of the algorithm
* Update ciphers/atbash_cipher.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update ciphers/atbash_cipher.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update ciphers/atbash_cipher.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* Update ciphers/atbash_cipher.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
* fix: Apply suggestions from code review
Co-authored-by: David Leal <halfpacho@gmail.com>
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
* Fixed array max length and coding style
Max length of arrays was previously an absurdly high integer, instead implemented a numerical upper bound using log2 (max depth of seg tree being logn). Removed `using namespace std;` and `typedef long long ll;` and other competitive coding practices. Added input prompts.
* Fixed remaining clang-tidy warnings
* Replaced reference parameters with const & or *
* Self-tests and documentation
* Improved documentation
* Added author names
Co-authored-by: David Leal <halfpacho@gmail.com>