-
- Notifications
You must be signed in to change notification settings - Fork 7.7k
Added heavy_light_decomposition.cpp #1016
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
Added heavy_light_decomposition.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
Co-authored-by: David Leal <halfpacho@gmail.com>
Co-authored-by: David Leal <halfpacho@gmail.com>
TODO: Data member documentation.
Added function documentation
Function documentation
Co-authored-by: David Leal <halfpacho@gmail.com>
Panquesito7 left a comment
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 enable GitHub Actions in your fork of this repository for refined code and formatting.
I'm not sure I did it right. Should I get any specific action from the marketplace? |
| Never mind, it seems GitHub Actions is already enabled. 😄 |
| Thank you for your time and guidance. Learnt a lot about writing refined code and proper documentation. Looking forward to contributing more to this repository! |
kvedala left a comment
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.
Co-authored-by: Krishna Vedala <7001608+kvedala@users.noreply.github.com>
Your code includes "tab-space" indentation which is disabled in the repo. Other formatting options are also not being seen. The Github Actions settings for this repo should have corrected that. |
| Does this look right? (Bear with me, I'm a little new around here).
@Panquesito7 said that it was enabled. I'm not sure what the issue is. |
It does look right. And reviewing the commit history, I do see the corrections made by |
| Meanwhile, if you can open this PR in GitPod using the link in the description above, when you press save, the appropriate fixes will be applied. you can commit therein; thus simplifying the process |
| } | ||
| } | ||
| std::vector<std::list<int>> | ||
| t_adj; ///> an adjacency list to stores the tree edges |
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.
| t_adj; ///> an adjacency list to stores the tree edges | |
| t_adj; ///< an adjacency list to stores the tree edges |
The comment is incorrect please note that the correct start tag is ///< and not ///>. Also note that this comment must fit on the same line.
Please make the corrections throughout the code.
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.
Looks like clang-format is breaking up the lines 😕.
Co-authored-by: Krishna Vedala <7001608+kvedala@users.noreply.github.com>
| @aneee004 what I recommended was a suggestion and example. By accepting it as is, the points got repeated in the lines below it. please check lines 327 with lines from 323. |
| My bad, did not notice it. I'll remove those. Also what about |


Description of Change
Added a new file heavy_light_decomposition.cpp, which supports point updates and path queries in a tree. The implementation is completely original, and implemented from scratch.
Checklist
Notes: Adding an implementation of Heavy-Light decomposition.