mirror of
https://github.com/TheAlgorithms/C-Plus-Plus.git
synced 2026-02-04 02:56:40 +08:00
* fix: set proper size of fac * style: use std::size_t as a type of loop counter * style: use uint64_t as a type of loop counter * fix: remove p from the argument list of NCRModuloP::ncr * refactor: add utils namespace * refactor: use references in gcdExtended * refactor: add NCRModuloP::computeFactorialsMod * style: make NCRModuloP::ncr const * test: reorganize tests * test: add missing test cases * refactor: simplify logic * style: make example object const * style: use auto * style: use int64_t to avoid narrowing conversions * docs: update explanation why to import iostream * docs: remove `p` from docstr of `NCRModuloP::ncr` * docs: udpate doc-strs and add example() * Apply suggestions from code review Co-authored-by: David Leal <halfpacho@gmail.com> * dosc: add missing docs * feat: display message when all tests pass Co-authored-by: David Leal <halfpacho@gmail.com> * style: initialize `NCRModuloP::p` with `0` Co-authored-by: David Leal <halfpacho@gmail.com> --------- Co-authored-by: David Leal <halfpacho@gmail.com> Co-authored-by: realstealthninja <68815218+realstealthninja@users.noreply.github.com>
5.9 KiB
5.9 KiB