Package to generate random facts
Project description
Randfacts is a python library that generates random facts. You can use randfacts.getFact()
to return a random fun fact. Disclaimer: Facts are not guaranteed to be true.
Example:
import randfacts
x = randfacts.getFact()
print(x)
will print a random fact like:
Penguins can't taste sweet or savory flavors, only sour and salty ones
This package has a filter option to filter out potentially inappropriate facts. The filter is on by default. To disable the filter, you can just set the filter
parameter to False
.
from randfacts import getFact
print(getFact(False))
If you want to access the list of facts directly, you can just import the safeFacts
, unsafeFacts
, or allFacts
lists from the randfacts module.
Randfacts can also be executed directly from the command line, with python3 -m randfacts
.
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
Built Distribution
Hashes for randfacts-0.5.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e17074c86e960dbe2fd91f708cb7aa96327b7daf1d94b3202ca03bbefda47610 |
|
MD5 | 40f13e1144094b4b8b9eab4b396f9c4d |
|
BLAKE2b-256 | e994eede7c6c7a4be4c667daf04c5ec0985fb35046eb0a35d4242e2c4f6ceea0 |