* add type hints to math/gcd
* add doctest
* math/gcd - run black formatter
* math/gcd: remove manual doctest
* add correction to gcd of negative numbers
* add more doctest in iterative gcd
* Made improvements to combinations.py
* Update maths/combinations.py
Co-authored-by: Du Yuanchao <shellhub.me@gmail.com>
* Function now raises an error when given invalid input
* Update maths/combinations.py
Co-authored-by: Du Yuanchao <shellhub.me@gmail.com>
* Add GitHub action file for pre-commit
* Fix errors exposed by pre-commit hook:
- Remove executable bit from files without shebang. I checked those
file and it was not needed.
- Fix with black
* Apply suggestions from code review
Co-authored-by: Christian Clauss <cclauss@me.com>
Co-authored-by: Christian Clauss <cclauss@me.com>
* Fix all errors mentioned in pre-commit run:
- Fix end of file
- Remove trailing whitespace
- Fix files with black
- Fix imports with isort
* Fix errors
* fix assignment of a variable to itself
* Fix unnecessary 'else' clause in loop
* formatting and redundant reasignment fix
* mark unreachable code with a TODO comment
* fix variable defined multiple times
* fix static method without static decorator
* revert unintended autoformatting
Co-authored-by: Christian Clauss <cclauss@me.com>
* revert autoformatting issue
* applied black autoformatting
Co-authored-by: Christian Clauss <cclauss@me.com>
* * support negative number
* add different version
* fixup! Format Python code with psf/black push
* sum(int(c) for c in str(abs(n)))
* updating DIRECTORY.md
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: Christian Clauss <cclauss@me.com>
* More efficient least common multiple.
* lowest -> least
* integer division
* Update least_common_multiple.py
Co-authored-by: Christian Clauss <cclauss@me.com>
* Correcting the Gaussian Formula
I have added the parenthesis around the 2*sigma^2 term.
* Update gaussian.py
* Update gaussian.py
* Update gaussian.py
* Update gaussian.py
* Update gaussian.py
* Update gaussian.py
Co-authored-by: Christian Clauss <cclauss@me.com>
* Added Python Program to Check Perfet Number
* CodeSpell Error Fix - 1
* Build Error Fix - 1
* Made suggested changes
* Use generator expression
* Added Python Program to Check Krishnamurthy Number or not
* Added Python Program to Check Krishnamurthy Number
* Added Python Program to Check Krishnamurthy Number or not
* Build Error Fix - 1
* Build Error Fix - 2
* Fix Brackets positions
* Fix Character Exceeding Error
* Made Review Changes
* Build Error Fix - 3
* Build Error Fix - 4
* Update krishnamurthy_number.py
Co-authored-by: Christian Clauss <cclauss@me.com>
* add surface area class
* add new line to end of file
* move surface area class into area class
* add missing import
* added pi import
* fix typo
* added blank line
* fixed more import issues
* comment fix
* comment fixes
* created perfect_cube.py
To find whether a number is a perfect cube or not.
* Update perfect_cube.py
* Update perfect_cube.py
* Update perfect_cube.py
* Added Lstm example for stock predection
* Changes after review
* changes after build failed
* Add Kiera’s to requirements.txt
* requirements.txt: Add keras and tensorflow
* psf/black
* haris corner detection
* fixup! Format Python code with psf/black push
* changes after review
* changes after review
* fixup! Format Python code with psf/black push
Co-authored-by: Christian Clauss <cclauss@me.com>
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
* create sum_of_digits.py
create sum_of_digits.py to find the sum of digits of a number
digit_sum(12345) ---> 15
digit_sum(12345) ---> 10
* Update sum_of_digits.py
* Update maths/sum_of_digits.py
Co-authored-by: Christian Clauss <cclauss@me.com>
* Update maths/sum_of_digits.py
Co-authored-by: Christian Clauss <cclauss@me.com>
* Update sum_of_digits.py
Co-authored-by: Christian Clauss <cclauss@me.com>
* Create number_of_digits.py
A python program to find the number of digits in a number.
* Update number_of_digits.py
* Update number_of_digits.py
* Add #1976 to get Travis CI to pass
#1976
* Add type hints as discussed in CONTRIBUTING.md
Co-authored-by: Christian Clauss <cclauss@me.com>
* Tighten up psf/black and flake8
* Fix some tests
* Fix some E741
* Fix some E741
* updating DIRECTORY.md
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
* Precision must be a nonnegative integer
* fixup! Format Python code with psf/black push
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
* consists of area of various geometrical shapes
In this program it consists of various area calculation of different geometrical shapes such as (square,rectangle) and many other shapes.
* print(f'Rectangle: {area_rectangle(10, 20)=}')
* Update area.py
* Areas of various geometric shapes:
Co-authored-by: Christian Clauss <cclauss@me.com>