/calculator

This is a simple calculator project built using Ruby, JavaScript, and CSS.

Primary LanguageHTML

Simple Calculator

This is a simple calculator project built using Ruby, JavaScript, and CSS. The calculator allows users to perform basic arithmetic operations such as addition, subtraction, multiplication, and division.

Example Code

Here's an example of how the calculator logic can be implemented in Ruby:

def add(num1, num2)
  num1 + num2
end

def subtract(num1, num2)
  num1 - num2
end

def multiply(num1, num2)
  num1 * num2
end

def divide(num1, num2)
  num1 / num2
end

# Example usage
result = add(5, 3)
puts result

This is just a basic structure and implementation of the calculator project. Feel free to customize and enhance it according to your specific requirements and desired functionality.