Coding Exercise Posts - page 19 of 43

Recent posts

Word Formation

1 minute read

Given a list of strings words and a string letters, return the length of longest string in words that can be made from letters in letters. If no word can be ...

Wolves of Wall Street

less than 1 minute read

Given a list of integers prices representing the stock prices of a company in chronological order, return the maximum profit you could have made from buying ...

Wolf of Wall Street

1 minute read

Given a list of integers prices representing the stock prices of a company in chronological order, return the maximum profit you could have made from buying ...

Virtual Boolean Array

1 minute read

Implement a boolean array which implements the following methods:

Vertical Lines in Binary Tree

1 minute read

Given a binary tree root, return the number of unique vertical lines that can be drawn such that every node has a line intersecting it. Each left child is an...

Vertical Cipher

less than 1 minute read

Given a string s and an integer k, rearrange s into k rows so that s can be read vertically (top-down, left to right).

Verify Max Heap

less than 1 minute read

Given a list of integers nums, return whether it represents a max heap. That is, for every i we have that:

Validate Delivery Orders

1 minute read

You are given a list of strings orders. Each element in orders starts with either "P" meaning pickup or "D" meaning delivery followed by the order id. For ex...

Upside Down Numbers

less than 1 minute read

An upside down number is one that appears the same when flipped 180 degrees. Given n, return all upside down numbers as strings whose length is n, sorted in ...

Unobstructed Buildings

1 minute read

You are given a list of integers heights representing building heights. A building heights[i] can see the ocean if every building on its right has shorter he...

Unix Path Resolution

1 minute read

Given a Unix path, represented as a list of strings, return its resolved version.

Univalue Tree

less than 1 minute read

Given a binary tree root, return whether all values in the tree are the same.