Skip to content

alternateved/calculator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Project: Calculator

Implementation of Calculator from The Odin Project using JavaScript, HTML and CSS.

Live preview of the project is available here.

Features

  • supported operations: division, multiplication, subtraction, addition, calculating percentage, changing sign
  • rounding to four decimal places
  • DEL button (to delete one symbol at a time) and AC button (to perform clear of all display and variables)
  • decimal button for floating-point operations
  • history of last operation
  • option to create portal to another dimension when dividing by zero
  • keyboard support
  • calculator evaluates a single pair of numbers at a time
  • operations buttons and decimal button (.) are prevented from pushing twice
  • responsive design: calculator is functional on desktop and mobile web browsers

Side notes

  • used CSS Flexbox to create website's layout
  • used CSS Grid to style calculator
  • learned how to implement keyboard support with HTMLElement.click() method
  • deepened knowledge of how functions work together

Tools

  • Visual Studio Code
  • Linux terminal
  • Git and GitHub
  • Adobe Color

Third party code