-
-
Notifications
You must be signed in to change notification settings - Fork 7.3k
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: pre existing algorithm area.cpp to follow guidelines #2522
Fix: pre existing algorithm area.cpp to follow guidelines #2522
Conversation
…rea.cpp-to-follow-guidelines
…existing-algorithm-area.cpp-to-follow-guidelines
…rea.cpp-to-follow-guidelines
…existing-algorithm-area.cpp-to-follow-guidelines
This is because when doing the multiplication we need to give these data | ||
types a wider area of memory when doing this calculation so we need a 64 | ||
bit variable. | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dont you think that sometimes we need to find areas of shapes with values with decimal points?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yea, I wanted to keep it simple though because of the context of this issue: #2456
I can update these to use floats if you guys want and add more checks. It will increase the complexity though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we need input from @Panquesito7 is this too simple? it will lack the functionality to do floats and doubles and decimals.
test(); // run self-test implementations | ||
test_square_area_functionality(); // run self-test implementations | ||
test_rect_area_functionality(); | ||
test_triangle_area_functionality(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please condense all these tests into a single function i.e
static void tests() {
test_**_**(); // more info on test
test_**_**(): // more info on test
}
This pull request has been automatically marked as abandoned because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Please ping one of the maintainers once you commit the changes requested or make improvements on the code. If this is not the case and you need some help, feel free to ask for help in our Gitter channel or our Discord server. Thank you for your contributions! |
Description of Change
The changes in this PR are to update legacy functionality to conform to the newer guidelines within this repo.
Checklist
Notes: