A commons library for Project Euler problems.
Project description
Leonhard
A commons library for Project Euler problems.
Requirements
- Python 3.x
Installation
pip install leonhard
Usage
>>> from leonhard import leonhard
>>> print(leonhard.get_factors_of_positive_integer(10))
[1, 2, 5, 10]
Functionalities
get_factors_of_positive_integer: Gets the factors of a given positive integergenerate_fibonacci_sequence: Generates a Fibonacci sequenceis_prime: Checks if a number is prime or notis_pythagorean_triplet: Checks if a^2 + b^2 = c^2 where a < b < ccount_digits: Counts the number of digits of a given numbergenerate_collatz_sequence: Generates a collatz sequencegenerate_cyclic_permutation: Generates the list of cyclic permutation of a given numberis_triangle_number(): Checks if a number is triangular or not
Samples
Sample files are found in samples/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
leonhard-1.6.5.tar.gz
(8.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file leonhard-1.6.5.tar.gz.
File metadata
- Download URL: leonhard-1.6.5.tar.gz
- Upload date:
- Size: 8.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.10.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3375af6bac215d6d823044864b6ceb48b391ceea8e251fdd54f1a8e765111a5a
|
|
| MD5 |
039ef555581d83461b3767fedcb2427d
|
|
| BLAKE2b-256 |
917eb219c238dcffbcebc39f7192aec34cda630298a705ee1498d72587a01750
|
File details
Details for the file leonhard-1.6.5-py3-none-any.whl.
File metadata
- Download URL: leonhard-1.6.5-py3-none-any.whl
- Upload date:
- Size: 9.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.10.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8b49e9075255340eb1d74479140dfb19ede073308cb599a1b392ee89b3441a12
|
|
| MD5 |
8c72236be3a0d00e8477e2c617f3719b
|
|
| BLAKE2b-256 |
439cb0223bd78d5ca99f449a0af89b2d80d78befd8112e117cde8c4661b2ccdb
|