Skip to main content

Calculator package for Turing College

Project description

Basic Calculator Package

This package was made as a project for Turing College course

After installation, import it as: from calculator.calculator import Calculator

Description:

This calculator is made as a class named Calculator.

There are 7 different Calculator class methods available.

5 of them are operations methods, 2 of them are memory methods.

Operations methods: (These methods take up to two arguments)

                .add(x,y) - Adds two numbers, x+y
                .substract(x,y) - Substracts two numbers, x-y
                .multiply(x,y) - Multiplies two numbers, x*y
                .divide(x,y) - Divides two numbers, x/y. Y cannot be assigned a value of zero.
                .nr(y,x) - Returns y-th root of x, example: .nr(2,4) 2nd root of 4 = 2 (square root in          this case)

Memory methods: (Memory methods dont take any arguments) .show_memory() - shows current memory value .clear_memory() - resets memory to value of 0

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

final_calculator_martin_macak-0.0.1.tar.gz (3.4 kB view details)

Uploaded Source

Built Distribution

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

final_calculator_martin_macak-0.0.1-py3-none-any.whl (4.2 kB view details)

Uploaded Python 3

File details

Details for the file final_calculator_martin_macak-0.0.1.tar.gz.

File metadata

File hashes

Hashes for final_calculator_martin_macak-0.0.1.tar.gz
Algorithm Hash digest
SHA256 f1a9b321c85d97523e75d3b3881bdbbec1093ede3444c8bf2f8d29b909b61bfd
MD5 bccdb48be7851ca899ad031411872435
BLAKE2b-256 3fa0e8dbdff1af9c9ed79f6a695cc771259e44317d7f788b8fa5c1e4d4a8bcd8

See more details on using hashes here.

File details

Details for the file final_calculator_martin_macak-0.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for final_calculator_martin_macak-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 ca0f59ee6bb7057a460fc90dc23a0491d457e51971f2e564cff3c65dbc75b1b1
MD5 921685def3293ca1ed3adde643d2d60a
BLAKE2b-256 f8e647e0ce417ea4438ce13691af6643d3f4d97d432f47198b598acc1278a0be

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