Walmart Labs Interview Experience | Java developer for 4.5 Years Experienced

Round 1:

1. Given a string containing only R and L. Find the number of balanced substrings(equal number of L’s and R’s) you will encounter where you can traverse only in the left-right direction.

Example 1: RLRRLLRLRL  Answer: 4 (RL, RRLL, RL, RL)

Example 2: LLLLRRRR  Answer:1 (LLLLRRRR)

Example 3: RLLLLRRRLR  Answer:3 (RL, LLLRRR, LR)



2. Given a tree and a node, find a list of neighbors who are not siblings of given node.

3. https://www.geeksforgeeks.org/detect-loop-in-a-linked-list/

Write your Interview Experience or mail it to contribute@geeksforgeeks.org

My Personal Notes arrow_drop_up

Check out this Author's contributed articles.

If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.

Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.


Article Tags :
Practice Tags :


Be the First to upvote.


Please write to us at contribute@geeksforgeeks.org to report any issue with the above content.