gurnell / simple_calculator

A simple calculator for python practice.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Simple Calculator

Python project

In this project, we are creating a simple calculator thta can add, subtract, multiply or divide depending on the user input. For this project, knowledge of the following python topics is needed:

  1. User-defied functions.
  2. Functions
  3. Function Arguments

About

We request the user to select an operation in this program. 1, 2, 3, and 4 are all viable choices. Any further input results will display Invalid Input, and the loop keeps going until a valid option is chosen.

A particular segment is carried out by using an if...elif...else branching and two numbers. The user-defined functions multiply(), divide(), add(), and subtract() evaluate their associated operations and display the output.

The output:

Screenshot (4)

About

A simple calculator for python practice.


Languages

Language:Python 100.0%