-
-
Notifications
You must be signed in to change notification settings - Fork 46.8k
improved implementation - all test passing now #6973
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
Conversation
…erse of 3x3 matrix
for more information, see https://pre-commit.ci
[pre-commit.ci] pre-commit autoupdate (#6940) * [pre-commit.ci] pre-commit autoupdate updates: - [github.com/psf/black: 22.8.0 → 22.10.0](psf/black@22.8.0...22.10.0) - [github.com/asottile/pyupgrade: v2.38.2 → v3.0.0](asottile/pyupgrade@v2.38.2...v3.0.0) - [github.com/pre-commit/mirrors-mypy: v0.981 → v0.982](pre-commit/mirrors-mypy@v0.981...v0.982) * updating DIRECTORY.md Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
A machine does |
>>> inverse_of_matrix([[1, 2, 2], [1, 2, 2], [3, 2, -1]]) | ||
Traceback (most recent call last): | ||
... | ||
ValueError: This matrix has no inverse. |
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 add some more doctests:
>>> inverse_of_matrix([])
>>> inverse_of_matrix([1])
>>> inverse_of_matrix([[], []])
>>> inverse_of_matrix([[1, 2], [3, 4], [5, 6]])
>>> inverse_of_matrix([[1, 2, 3], [4, 5, 6]])
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.
Ok sir, I am adding
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.
Done sir
@algorithms-keeper review-all If possible, please fix them. |
Describe your change:
Checklist:
Fixes: #{$ISSUE_NO}
.