Skip to content

Refactor Calculator project to object-oriented design#30

Open
ubaids12 wants to merge 1 commit into
sohailburki01:mainfrom
ubaids12:main
Open

Refactor Calculator project to object-oriented design#30
ubaids12 wants to merge 1 commit into
sohailburki01:mainfrom
ubaids12:main

Conversation

@ubaids12

@ubaids12 ubaids12 commented Jun 3, 2026

Copy link
Copy Markdown

Summary

This PR refactors the Calculator project from a functional programming approach to an object-oriented design.

Changes Made

  • Added a Calculator class to encapsulate calculator operations.
  • Converted arithmetic functions into class methods.
  • Improved code organization and maintainability.
  • Preserved the existing calculator functionality and user experience.

Testing

  • Tested addition, subtraction, multiplication, division, exponentiation, and nth-root operations.
  • Verified that the calculator runs successfully after refactoring.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant