https://github.com/sampoder/pyclid
🤔 Pyclid is a simple python module / library that calculates the highest common factor based on Euclid's Algorithm.
https://github.com/sampoder/pyclid
Last synced: 10 months ago
JSON representation
🤔 Pyclid is a simple python module / library that calculates the highest common factor based on Euclid's Algorithm.
- Host: GitHub
- URL: https://github.com/sampoder/pyclid
- Owner: sampoder
- Created: 2019-04-18T12:26:43.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2020-06-10T06:59:27.000Z (over 5 years ago)
- Last Synced: 2025-02-08T04:44:30.109Z (12 months ago)
- Language: Python
- Homepage:
- Size: 10.7 KB
- Stars: 3
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# 🤔 pyclid
 
Pyclid is a simple python library that calculates the highest common factor based on [Euclid's Algorithm](https://en.wikipedia.org/wiki/Euclidean_algorithm).
## Set Up
To create an example python script that uses the Pyclid library run the simple commands below with Terminal, Command Prompt or your OS's alternative. Then use a text editor to edit the file we will create.
Note: You will need to install [Python](https://www.python.org/downloads/).
## Linux & Mac
```bash
mkdir Pyclid-Example
cd Pyclid-Example
git clone https://github.com/sampoder/pyclid.git
touch example.py
nano example.py #Include all the python code below.
#Make sure to save the file correctly
python example.py
```
## Windows
```bash
mkdir Pyclid-Example
cd Pyclid-Example
git clone https://github.com/sampoder/pyclid.git
echo . -> example.py #We will delete the dot later
edit example.py #Include all the python code below and delete the "." we made.
#Make sure to save the file correctly
python example.py
```
## Python Code
Place the below code in your example.py document
```python
from Pyclid import pyclid #Here we import our library
x = pyclid.returnHCF(288,160) #Here we call the library with our two numbers.
# Important: Make sure our larger number comes first.
print(x) #Here we display our results
```
## Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
If you find a bug please report it using GitHub Issues.
## License
[MIT](https://choosealicense.com/licenses/mit/)