Skip to content

rijadhmz/JavaScript-Calculator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JavaScript Calculator

This project involves building a functional JavaScript calculator, which allows users to perform mathematical operations. The calculator can be accessed Here.

Project Description

The JavaScript calculator is an interactive web application built to perform basic arithmetic calculations. Users can input numbers, apply operators, and calculate results through either clicking on calculator buttons or using keyboard input. The calculator supports a range of mathematical operations and adheres to proper calculation order.

Challenge Requirement

The challenge required building an app similar to this example. The following user stories were fulfilled:

  1. The calculator should include clickable buttons for digits 0-9.
  2. Operators (+, -, *, /) should have clickable buttons.
  3. A clickable button for the decimal point should be available.
  4. The calculator should have a button to clear the input and output values.
  5. A clickable button for the equals sign (=) should calculate and display the result.
  6. The calculator display should show the current input as users interact with it.
  7. The calculator should handle order of operations and chaining of operations.
  8. The calculator should handle decimal numbers and precision.
  9. Pressing an operator immediately after = should continue calculations.
  10. The calculator should handle zero input limitations and multiple decimals.

Implementation Details

The project is built using React and Redux, providing a dynamic and user-friendly interface. The calculator's functionality is achieved through React components and Redux actions, allowing for clear state management and interaction logic. The calculator handles various edge cases, including consecutive operators, decimal input, and zero input scenarios.

Technologies Used

  • React
  • Redux
  • Bootstrap (for styling)

Example

JavaScript Calculator

Project URL

To interact with the deployed project, visit my CodePen Project.

This project demonstrates effective use of React and Redux for creating an interactive calculator that performs various arithmetic operations, adheres to order of operations, and handles user input gracefully.

About

React & Redux project for FreeCodeCamp "Front End Development Libraries" course.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published