Skip to main content

A few useful functions

Project description

This is a simple library with functions I use or wanted to make for fun. I’ll update with new functions when I’ll need them !

Change Log

1.0 (26/08/2020)

  • First Release :

    • Function showlist : takes a list and prints it into the console.

    • Function squareroot : outputs the square root of the number you give.

    • Function listprimes : lists every prime up to the number you give.

1.0.1 (11/09/2020)

  • Additions :

    • Class primes :

      Function isprime : outputs True if the number you gave it is prime.

    • Class math :

      Function absolute : an alternative to the “abs” function in python.

    • Class logic :

      Function logicand, logicnand, logicor, logicnor, logicxor, logicnot : these are logic gates. They take 2 booleans (1 for logicnot) and output a boolean. All these functions are branchless !

    • Class lists :

      More in the “Modifications” paragraph

  • Modifications :

    • Class primes :

      The “listprimes” function is here now. You can now also set a starting point for the listing but it is optional.

    • Class math :

      The “squareroot” function is here now and it’s called “root” because you can now specify if you want the square root, the cubic root… It is optional so by default it outputs the square root.

    • Class lists:

      The “showlist” function is now here and it’s name is now “show” because it is already in a list class !

I will maybe change the way it is organized, but I don’t think it will change the way everything behaves.

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

mypythonutils-1.0.1.tar.gz (3.4 kB view details)

Uploaded Source

File details

Details for the file mypythonutils-1.0.1.tar.gz.

File metadata

  • Download URL: mypythonutils-1.0.1.tar.gz
  • Upload date:
  • Size: 3.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.5

File hashes

Hashes for mypythonutils-1.0.1.tar.gz
Algorithm Hash digest
SHA256 b8655380b575b0c09a29caa6eb204793af3a52f80f5ff89ad10ecde208fede15
MD5 5b28a11e2ddc0635f952dba0321dbfa2
BLAKE2b-256 6f15cd4c48afa441c64137af4ef010192951f89ccaec7d81dcdec69c7a9ea062

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