Python tools for doing stuff with letters.
Project description
Letter Tools
This is a very simple module that allows you to randomly get letters and make letter for loops.
Installing
To install use this command:
$ pip install letter-tools
Examples
First an example for randomly picking a letter.
>>> from letter_tools import rand
>>> rand("a", "h")
c
>>> rand("a", "h")
g
>>> rand(1, 10)
5
>>> rand(1, 10)
7
Another example for randomly picking a letter out of numbers.
>>> from letter_tools import randlet
>>> randlet(4, 8)
h
>>> randlet(5, 7)
e
Next an example for ranges.
>>> from letter_tools import Range
>>> for i in Range("i"):
... print(i)
...
a
b
c
d
e
f
g
h
i
>>> for i in Range("d", "g"):
... print(i)
...
d
e
f
g
>>> for i in Range(1, 5):
... print(i)
...
1
2
3
4
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
letter-tools-0.0.4.tar.gz
(2.2 kB
view hashes)
Built Distribution
Close
Hashes for letter_tools-0.0.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b286ea3423cd4653482aad919801a2834e3fb13216672f4adeed17f58d54bb24 |
|
MD5 | c9591625f49cab5d32f35b0395d80785 |
|
BLAKE2b-256 | 8ca98ad5f48c55a977a66cf1c06c87d961240d110e28c60b846c47b745ac1d73 |