Skip to main content

A package that gives quotes from the professor

Project description

Bloomsays ๐Ÿ‘จโ€๐Ÿซ

CI PyPI version

What is Bloomsays?

Bloomsays is a fun python package with some of our favorite lines from Professor Bloomberg.

Installation

Here is the link to the PyPi page

pip install bloomsays

Usage

Ater installation, you can import and call the functions from the package

from bloomsays.wisdom import avg, random_quote, coding_wisdom, study_tip, jokes

# Get your average grade
avg(90, 80, 100)

# Get a random quote from Professor Bloomberg!
random_quote()

# Get some coding wisdom with your specified language
coding_wisdom("Python")

# Get personalized study tips
study_tip(hours_available=3, difficulty="hard")

# Enjoy some programming humor
jokes(2)

Functions

For a demonstration of all functions, see example.py.

avg(*grades)

Calculate the average of your grades and display it with Professor Bloomberg's majestic ASCII art.

Parameters:

  • *grades (float): Variable number of grade values (integers or floats)

Returns:

  • float: The calculated average

Raises:

  • ValueError: If no grades are provided

random_quote(n=1)

Display random inspirational (and occasionally intimidating) quotes from Professor Bloomberg's legendary syllabus and course communications.

Parameters:

  • n (int, optional): Number of quotes to display. Default is 1. Must be at least 1.

Returns:

  • list: List of the selected quote strings

Raises:

  • ValueError: If n is less than 1

coding_wisdom(language="Python")

Receive programming wisdom from Professor Bloomberg tailored to your specific language. Because different languages have different philosophies!

Parameters:

  • language (str, optional): Programming language name. Default is "Python".
    • Supported languages: "Python", "JavaScript", "Java", "C++"
    • Any other language uses general programming wisdom

Returns:

  • str: The wisdom message (without the language prefix)

study_tip(hours_available=2, difficulty="medium")

Get personalized study advice from Professor Bloomberg based on your available time and the difficulty of your material. The advice adapts to your situation!

Parameters:

  • hours_available (float, optional): Number of hours you have to study. Default is 2. Must be non-negative.
  • difficulty (str, optional): Difficulty level of the material. Options: "easy", "medium", or "hard". Default is "medium". Case-insensitive.

Returns:

  • str: A personalized study tip (base tip without the time advice)

Raises:

  • ValueError: If hours_available is negative

jokes(n=1)

Get random programming jokes to lighten the mood during those long debugging sessions. Laughter is the best debugger!

Parameters:

  • n (int, optional): Number of jokes to display. Default is 1.

Returns:

  • list: List of the selected joke strings

Example Program

Want to see all functions in action? Check out our example.py file!


Example Output

  ______________
 | ask Bloombot |
  ==============
       \
        \

        @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@&%%%##(##&@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@@@@@@@@@@%%%#%%%%%%%%%#######%@&@@@@@@@@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@@@@@@@%%#%%&%%%###%%####(#%&&&%%%%&&@@@@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@@@@%&&&&&#((///((((////**////(#&&&&&&%@@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@&&&&&&%#(////***************////(#@@&&&@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@&&&@&#(///***************,*****///(&@&&&@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@&&&&&#(///********,,,,,,,,,,,****///(&&&&&@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@&&&&%(////*****,*,*,,,,,,,,,,,,****//#&&@&@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@&&&&&%(////*******,,,,,,,,,,********//(&&&&&@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@&@&&&%////**********,,,,,,,,,,******//(%&&&&@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@&@@&&%(///*******,,,,,,,,,,,,,,******//#&@&&@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@&&@@&%(///(#(####(/****,**//(%%%%##(///(&&&@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@&&&&(//%###%##%%###(/***/(((%&&&&%###((&@&//@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@(((#&&(//(#%#(*##,/(/(/***///(**#*/(((///&%#((/@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@/(//&&(//***//*////////****/*****/******/#(**/*@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@/(/(%&(//***/*******//**,,*/*******,,**//##(*/@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@/(#(&(///*********///*,,,,*//*********//%%(*#@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@///&%(//********/////****///*******///(&%//&@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@(/&&##((///**//((#&##%####(//***//(###&#/&@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@@(&&&&%#(/(%%###%%%##%##%%%((##(((##%&&&@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@@@&&&&%##%&%&&%###%##((###%%%%#%%%%%&&&@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@@@@&&&&&&%&%%#//(////////////%&&&#&&&&@@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@@@@@(%&@&&&&%#((((###%##((((((%&&&&@&%@@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@@@,#%/#&&&&&&&&%##%%#%%%##(#%&&%&&@&@@@@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@@..(&//(&&&&&&&&&%%%%#%%(%%&&@&&@%(@@@@@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@@....,///(%&&&&@&&&&%%%%%&&&&@@@&(/..@@@@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@@@@.......////((#%&&&&&&@&&&@&@&&@%(//*,../@@@@@@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@@@@@............//(((((((##&&@@@@@&&#/////#,,......(@@@@@@@@@@@@@@@@
        @@@@@@@@@@@@%..........    ...*///////(((((((//////*//&(.......... *@@@@@@@@@@@@
        @@@@@@@@@%.                 ..,..//**///////////****//%/*. ............ .&@@@@@@
        

Project Structure

.
โ”œโ”€โ”€ .github/                # GitHub Actions workflows
โ”‚   โ””โ”€โ”€ workflows/
โ”‚       โ””โ”€โ”€ build.yaml
โ”œโ”€โ”€ src/                    # Source code
โ”‚   โ””โ”€โ”€ bloomsays/
โ”‚       โ”œโ”€โ”€ __init__.py
โ”‚       โ”œโ”€โ”€ __main__.py
โ”‚       โ”œโ”€โ”€ bubble.py
โ”‚       โ””โ”€โ”€ wisdom.py
โ”‚   โ””โ”€โ”€ example.py
โ”œโ”€โ”€ tests/                  # Test files
โ”‚   โ”œโ”€โ”€ test_bubble.py
โ”‚   โ””โ”€โ”€ test_wisdom.py
โ”œโ”€โ”€ .gitignore
โ”œโ”€โ”€ LICENSE
โ”œโ”€โ”€ Pipfile                 # Pipenv dependencies
โ”œโ”€โ”€ Pipfile.lock
โ”œโ”€โ”€ pyproject.toml          # Project configuration for packaging
โ”œโ”€โ”€ README.md
โ””โ”€โ”€ TODO

๐Ÿ› ๏ธ Developer Guide

To contribute to this project, first set up your local development environment:

# 1. Clone the repository
git clone https://github.com/swe-students-fall2025/3-python-package-team_orchid.git
cd 3-python-package-team_orchid

# 2. Install dependencies using Pipenv
pipenv install --dev

# 3. Activate the virtual environment
pipenv shell

After setup, you can run tests, build the package, and test your changes.

Running Tests

Run the complete test suite with verbose output:

pytest tests/ -v

You can also run tests for specific files or functions:

# Test only the wisdom functions
pytest tests/test_wisdom.py

# Test a single specific test
pytest tests/test_wisdom.py::Tests::test_avg_simple

Contributors

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

bloomsays-0.2.5.tar.gz (48.8 kB view details)

Uploaded Source

Built Distribution

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

bloomsays-0.2.5-py3-none-any.whl (33.6 kB view details)

Uploaded Python 3

File details

Details for the file bloomsays-0.2.5.tar.gz.

File metadata

  • Download URL: bloomsays-0.2.5.tar.gz
  • Upload date:
  • Size: 48.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for bloomsays-0.2.5.tar.gz
Algorithm Hash digest
SHA256 f954d0cf7875e5c29e0419ab6a3b414fb4df98fe1a74c2953d35919d29fa991c
MD5 df4fda6b53081e242b50a72e175ec6ef
BLAKE2b-256 3432bae4b9d008f8c7bb1ffe7e4850455e74ef15901e67669161d2763a269672

See more details on using hashes here.

File details

Details for the file bloomsays-0.2.5-py3-none-any.whl.

File metadata

  • Download URL: bloomsays-0.2.5-py3-none-any.whl
  • Upload date:
  • Size: 33.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for bloomsays-0.2.5-py3-none-any.whl
Algorithm Hash digest
SHA256 c889fc789e59d65d15d4f486b24268c198b313f756349411f2617a33e5ee17f5
MD5 b68d786c86ae9cf0b134a15b96f4a2e0
BLAKE2b-256 d28dc5ae8becc2fc43793cd60d8348593a1b798cb39915bdc62682521139f7d3

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