Skip to main content

A lightweight utility library with numeric and text-processing helpers.

Project description

buddies-tools

A lightweight Python utility library with handy numeric and text-processing helper functions.

Installation

pip install buddies-tools

Modules

numeric_tools

  • mean(numbers) — arithmetic mean of a list of numbers
  • median(numbers) — median value of a list of numbers
  • is_prime(n) — checks whether a number is prime
  • factorial(n) — computes n!

text_tools

  • reverse_string(text) — reverses a string
  • is_palindrome(text) — checks whether a string is a palindrome
  • count_vowels(text) — counts vowels in a string
  • to_title_case(text) — converts a string to title case

Quick Example

from buddies_tools import mean, is_prime, reverse_string, is_palindrome

print(mean([1, 2, 3, 4]))                              # 2.5
print(is_prime(17))                                      # True
print(reverse_string("hello"))                           # olleh
print(is_palindrome("Was it a car or a cat I saw"))       # True

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

buddies_tools-0.1.0.tar.gz (2.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

buddies_tools-0.1.0-py3-none-any.whl (3.6 kB view details)

Uploaded Python 3

File details

Details for the file buddies_tools-0.1.0.tar.gz.

File metadata

  • Download URL: buddies_tools-0.1.0.tar.gz
  • Upload date:
  • Size: 2.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.9

File hashes

Hashes for buddies_tools-0.1.0.tar.gz
Algorithm Hash digest
SHA256 2efc29e7bb9de1f49f516a48c085012267a4eed22b8c15071f1eb683416f7dc8
MD5 1193644dd1927456f11bcac45d911535
BLAKE2b-256 b77d8cbfd7aebac36c90e7ef05a5e59133e9e3b9cedef595151d986893921bab

See more details on using hashes here.

File details

Details for the file buddies_tools-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: buddies_tools-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.9

File hashes

Hashes for buddies_tools-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 809a84f5b42a56ae038cf26b5d5a0bff4dce2944182c5a768df0166251f675be
MD5 e12525a4d53559383dbae491d3f49b19
BLAKE2b-256 48e979b50ce1059451dbcf9c27ee9d2a56a0a75436da8f5273a57ba00e7270e4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page