Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: formula to calc profit and loss % fix #4

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

gautam-balamurali
Copy link

  • Formula to calculate profit and loss percentage is not taking quantity into accounts.
  • var lossPercentage = (loss / initial) * 100; => var lossPercentage = (loss / (initial * quantity)) * 100;
  • var profitPercentage = (profit / initial) * 100; => var profitPercentage = (profit / (initial * quantity)) * 100;

@netlify
Copy link

netlify bot commented Dec 30, 2022

Deploy Preview for build-profit-or-loss failed.

Name Link
🔨 Latest commit 924cbd2
🔍 Latest deploy log https://app.netlify.com/sites/build-profit-or-loss/deploys/63aea5100e295a0009acb942

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