2762. Continuous Subarrays
You are given a 0-indexed integer array nums. A subarray of nums is called continuous if: Let i, i + 1, …, jbe the indices in the subarray. Then, for […]
You are given a 0-indexed integer array nums. A subarray of nums is called continuous if: Let i, i + 1, …, jbe the indices in the subarray. Then, for […]
You are given a 0-indexed array nums and a non-negative integer k. In one operation, you can do the following: Choose an index i that hasn’t been chosen before from the
You are given a string s that consists of lowercase English letters. A string is called special if it is made up of only
An array is considered special if every pair of its adjacent elements contains two numbers with different parity. You are given an
You are given a 0-indexed 2D integer array of events where events[i] = [startTimei, endTimei, valuei]. The ith event starts at startTimeiand ends at endTimei, and if you attend
You are given an integer array nums where the ith bag contains nums[i] balls. You are also given an integer maxOperations. You can perform the following operation
You are given an integer array banned and two integers n and maxSum. You are choosing some number of integers following the below rules: The
You are given two strings start and target, both of length n. Each string consists only of the characters ‘L’, ‘R’, and ‘_’ where: The characters ‘L’ and ‘R’ represent pieces, where a piece ‘L’ can
You are given two 0-indexed strings str1 and str2. In an operation, you select a set of indices in str1, and for each index i in the set, increment str1[i] to the
You are given a 0-indexed string s and a 0-indexed integer array spaces that describes the indices in the original string where spaces will be added. Each space
Given a sentence that consists of some words separated by a single space, and a searchWord, check if searchWord is a prefix of any word in sentence.
Given an array arr of integers, check if there exist two indices i and j such that : i != j 0 <= i, j <