Skip to main content

Easily get valid numeric and boolean input from user

Project description

You may need to prompt the user for a numeric or a boolean value
However what if the user types something invalid ?
This library solves this difficult problem with simplicity
marianoinput has PenguinPrompt, with which you can use to easily get valid user input.
If user inputs invalid input, then it will re-prompt the user

Sample Code..

from marianoinput import PenguinPrompt
pen= PenguinPrompt()

age=pen.prompt_int_range("whats you age ?", 18,100)
height=pen.prompt_float_range("whats you height in meters ?",1,3)
yesno= pen.prompt_yesno("Do you wish to continue ?")
print(age, height, yesno)

If you like this library check out my other libary "marianodoc" for producing word docs
https://pypi.org/project/marianodoc/

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

marianoinput-0.0.6-py3-none-any.whl (6.1 kB view details)

Uploaded Python 3

File details

Details for the file marianoinput-0.0.6-py3-none-any.whl.

File metadata

File hashes

Hashes for marianoinput-0.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 d0e37fa937ada4e95dcdb377ea5ec1760c945b6457ae4670450dd692bb162a77
MD5 ca37ec370f42d2182df44eef74a29ca9
BLAKE2b-256 4cacb960efa2a794bf6b7e056da9c8dd98b28aeab709064f1b10e2fcfe510f98

See more details on using hashes here.

Supported by

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