Showing 3 of 7 questions
Determine how many strings from a given list are subsequences of a larger input string. A subsequence can be formed by deleting characters from the larger string without changing the order of the remaining characters.
#1. Number of Matching Subsequences
Design a data structure that acts as a Least Recently Used (LRU) cache. Implement methods to get and put key-value pairs, evicting the least recently used entry when the cache is full.
#2. LRU Cache
You are given a graph representing cities and roads. Assign each city a value such that the total importance of all roads (sum of the values of the cities connected by each road) is maximized.
#3. Maximum Total Importance of Roads
Page 1 of 1 · 7 total