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

[Feat] Point Arithmetic: Scalar Division #6

Closed
1 of 4 tasks
SharonIV0x86 opened this issue Feb 9, 2025 · 2 comments · Fixed by #18
Closed
1 of 4 tasks

[Feat] Point Arithmetic: Scalar Division #6

SharonIV0x86 opened this issue Feb 9, 2025 · 2 comments · Fixed by #18
Assignees
Labels
Easy Easy tag for JWOC contributors. Feature addition Lable for a new Feature Addition good first issue Good for newcomers JWOC Role for JWOC contributors.

Comments

@SharonIV0x86
Copy link
Collaborator

SharonIV0x86 commented Feb 9, 2025

Title : Implement scalar division for points
Description:
Implement the operator / for the Point class to allow division of a point by a scalar value. The result should be a new Point object where each coordinate is divided by the scalar. Handle division by zero gracefully.
Function Signature:

Point<T, Dim> operator/(T scalar) const;

File: Point.hpp
Class: Point
Acceptance Criteria:

  • Add the operator/ function to the Point class.
  • Ensure the function works for points of any dimension.
  • Handle division by zero by throwing an exception or returning a meaningful error.
  • Write unit tests to verify the correctness of the implementation.
@SharonIV0x86 SharonIV0x86 added JWOC Role for JWOC contributors. Easy Easy tag for JWOC contributors. good first issue Good for newcomers Feature addition Lable for a new Feature Addition labels Feb 10, 2025
@ignorant05
Copy link
Contributor

assign me this issue @SharonIV0x86

@SharonIV0x86
Copy link
Collaborator Author

assign me this issue @SharonIV0x86

@ignorant05 Assigned to you.

Make sure you read the contribution guidelines and if you need any help feel free to ping me here. 👍🏼

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Easy Easy tag for JWOC contributors. Feature addition Lable for a new Feature Addition good first issue Good for newcomers JWOC Role for JWOC contributors.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants