This program coded entirely in Python version 3.9 is built upon the deductive logic of two declarative statements I've proven before: the Euclidean Algorithm's highest common factor and the LCM. With this program I demonstrate the capability of those results by providing my implementation of the results into this program.
This is an implementation of an inductive euclidean algorithm such that it allows you to compute the HCF and LCM of any n number of integers.
Also features extended euclidean algorithm, which outputs Bezout's Identity, with a patch to make it only output positive coefficient of the smaller integer in Bezout's Identity.
Python Interpreter 3+ is required in order to compile the code, you may build this into an executable through other means if you wish. Standard compilation is all that is needed.
python Euclidean_Algorithm_for_2_or_more_numbers_main.py
Once the code is executed, you will be provided with a prompt asking you the number of integers you'd like to compute the HCF and LCM of, as well as the integers themselves. For Bezout's Identity you'll need to call upon it by making your own script.
git clone https://github.com/faycalki/Euclidean_Algorithm_for_2_or_more_numbers.git
- Efficiently computes the greatest common divisor of any n number of integers, as well as their lowest common multiple.
- Minimal dependencies.
- Can be implemented as a fully modular program with minimal editing.
- Extended euclidean algorithm, which outputs Bezout's Identity, with a patch to make it only output positive coefficient of the smaller integer in Bezout's Identity.
If you'd like to contribute, please fork the repository and use a feature branch. Pull requests are warmly welcome.
- Repository: https://github.com/faycalki/Euclidean_Algorithm_for_2_or_more_numbers/
- Issue tracker: https://github.com/faycalki/Euclidean_Algorithm_for_2_or_more_numbers/issues/
- In case of sensitive bugs like security vulnerabilities, please contact icechillgaming@gmail.com directly instead of using the issue tracker. I greatly appreciate any efforts to improve the security of my projects.
- My other projects, feel free to check them out: https://github.com/faycalki/
The code in this project is licensed under the GNU General Public License v3.0.
This project is intended to be used for legal purposes only, and is pursuant to the license terms and conditions provided.