Skip to content

danpouma/Prefix-Notation-Calculator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

Print instructions explaining how to operate the calculator Allow the user to continue entering calculations until they quit the program Allow the user to perform the following operations: - add ( + ) should add to doubles - subtract ( - ) should subtract to doubles - multiply ( * ) multiply two doubles - divide ( / ) divide two doubles, do not allow division by zero - power ( ^ ) a double and an integer, calculate the double raised to the integer. zero and negative exponents should work. - exponential ( e ) raise the constant e to the power of the integer provided. zero and negative exponents should work. (you must define the constant) - factorial ( ! ) given an integer, calculate the factorial. store your result as a long - random range ( r ) given two integers, generate a random integer between the two integers (inclusively). Be sure the lower bound is less than the upper bound - sum range ( s ) calculate the sum of consecutive integers between two given integers (inclusively) - round ( ~ ) given a double, round to the nearest integers - roundup ( ' ) given a double, round to the nearest integers - rounddown ( _ ) given a double, round to the nearest integers - minimum ( < ) given two doubles, determine the lesser - maximum ( > ) given two doubles, determine the greater Allow the user to input the calculation all at once (examples below) + 3 4 / 4.3 2.3 ^ 3.1 2 r 5 10 Your code must meet the following technical specifications - use at least two variables of different types - no global variables allowed - use a constant, global constants are ok - use at least one if or if else statement - use at least one switch statement - use at least one for loop - use at least one while or do while loop - use at least three functions with prototype. - at least one must return a value - at least one must take input

About

calculator that uses prefix notation and no libraries

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages