Category: algorithms
Given an array of integers A, return the largest integer that only occurs once. If no integer occurs once, return -1. Example 1: Input: Output: 8 Explanation: The maximum …
Given an array of integers A, return the largest integer that only occurs once. If no integer occurs once, return -1. Example 1: Input: Output: 8 Explanation: The maximum …
Given a paragraph and a list of banned words, return the most frequent word that is not in the list of banned words. It is guaranteed there is at …
There are N cities numbered from 1 to N. You are given connections, where each connections = represents the cost to connect city1 and city2 together. (A connection is …
Given a string S, return the number of substrings of length K with no repeated characters. Example 1: Input: S = “havefunonleetcode”, K = 5 Output: 6 Explanation: There …