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

added Next Greater Node in Linked List #1722 #1754

Merged
merged 1 commit into from
Nov 8, 2024

Conversation

SKG24
Copy link
Contributor

@SKG24 SKG24 commented Nov 8, 2024

Given the head of a linked list with n nodes, find the value of the next node that is strictly greater for each node in the list. If no such node exists, return 0 for that position.

Return an integer array answer where answer[i] is the value of the next greater node of the ith node (1-indexed).

Screen.Recording.2024-11-08.at.4.26.49.PM.mov

Screenshot 2024-11-08 at 4 27 26 PM

gssoc-ext

Given the head of a linked list with `n` nodes, find the value of the next node that is strictly greater for each node in the list. If no such node exists, return `0` for that position.

Return an integer array `answer` where `answer[i]` is the value of the next greater node of the `i`th node (1-indexed).
@pankaj-bind pankaj-bind merged commit 53aabc8 into AlgoGenesis:main Nov 8, 2024
1 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants