Tag: c++
Given a singly linked list node, reorder it such that we take: the last node, and then the first node, and then the second last node, and then the …
Given a Unix path, represented as a list of strings, return its resolved version. In Unix, “..” means to go to the previous directory and “.” means to stay …
Given a list of integers nums and an integer k, return the maximum values of each sublist of length k. Constraints 1 ≤ n ≤ 100,000 where n is …
You are given a binary tree root representing a game state of a two person game. Every internal node is filled with an empty value of 0 while the …
Given the root to a binary tree root, return a list of two numbers where the first number is the number of leaves in the tree and the second …